The model is small and quantised, and it is downloaded on first run rather than bundled so the install stays a reasonable size. The native runtime it runs on is pinned to a specific release rather than tracking its main branch, so the native build stays reproducible and auditable.
Between that runtime and the app sits a hand-written bridge exposing a deliberately minimal API. Keeping that surface small and stable isolates the app from the runtime's internal churn, and makes the native boundary — the place where a mistake becomes a crash rather than an exception — small enough to reason about and test exhaustively.
Inference runs off the UI thread, so a slow or stalled generation never freezes the app. And the interface is deliberately runtime-agnostic: a different on-device runtime can be swapped in behind the same seam without the change rippling outward.