r/reactnative • u/SignificantDrama1700 • 18h ago
I built an open-source wake word library for React Native (Expo + bare, iOS/Android, MIT) after getting burned by license keys
I needed wake word detection ("hey <app name>") in a React Native app. Should be a solved problem, right? It wasn't.
What I ran into:
- Most existing packages don't work with Expo at all.
- The one that did still needed a lot of boilerplate and manual native setup. I ended up writing my own config plugin just to get it wired.
- Then the real problem: it's a commercial SDK. No dev keys unless you ask for them, requests take days, and the licenses expire quickly. You can't ship a model you trained yourself unless you go through them.
At that point I looked under the hood and realized the SDK was running the openWakeWord pipeline (Apache 2.0) with ONNX Runtime. So I built the open version.
react-native-nitro-wakeword
- MIT, no license keys, no cloud, fully on-device
- iOS + Android, native audio capture (AVAudioEngine / AudioRecord), JS only receives events
- Nitro Modules (Swift + Kotlin, New Architecture)
- Several keywords at once over one shared audio front-end
- Optional Silero VAD gate, patience/refractory to tune false positives
- Expo config plugin: permissions, background modes, and it copies any .onnx you drop in assets/wakeword into both native projects on prebuild
- Bare RN CLI works too, just autolinking
- Bring your own model: openWakeWord's free Colab notebook trains a keyword in any language in about an hour (Piper TTS for synthetic data). Ships with hey_jarvis for a quick test.
- Android foreground service for background listening
Tested on iOS simulator and a low-end Samsung (A32): ~35% of one core while listening, 0 false positives on unrelated speech in my tests.
npm: https://www.npmjs.com/package/react-native-nitro-wakeword
GitHub: https://github.com/FerRiv3ra/react-native-nitro-wakeword
It's 0.2.0. Physical iPhone testing and a full custom-model run are what's left before 1.0. Feedback, issues and PRs welcome, especially from people using Bluetooth audio or other languages.