Edge → Cloud → Browser
The same Python step functions that run on a POS terminal or cloud worker run here, natively in your browser tab via Pyodide + WebAssembly.
Validates items and totals, fans out to two warehouse APIs in parallel, then either ships or places a backorder based on stock availability.
Generates 10 synthetic sensor readings with injected anomalies, computes statistics, and branches to an alert if the anomaly rate or σ is high.
Embeds the transaction description using a sentence transformer model running on WebGPU (or WASM fallback), scores against risk pattern embeddings via cosine similarity, then approves, flags, or declines.
Model settings
Abstractive summarisation using Qwen2.5-0.5B-Instruct (q4). A DECISION step validates compression ratio; if the output is too short it jumps to an extractive sentence fallback — a workflow-level quality gate.
A bert-base-NER model runs entirely on-device to strip person names and IDs from the raw report. The redacted payload is severity-routed by the DECISION step and written to local IndexedDB as a Store-and-Forward record — PII never touches the network.
A complexity classifier routes simple queries to the fast path (first URL only). Complex prompts trigger full inference. SmolLM2-135M (88 MB) fits everywhere including Safari. Qwen2.5-0.5B (395 MB) gives higher quality on Chrome/Edge desktop.