Skip to content

Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.

feat(wake): ship word-agnostic openWakeWord backbones in-repo

Ruben Lütke19af1f1884ea
diff --git a/.gitignore b/.gitignore
index c684982d7f..2a04e61489 100644
--- a/.gitignore
+++ b/.gitignore
@@ -70,6 +70,12 @@ models/
# wake models, Whisper cache) stay ignored. NOTE: the bundled openWakeWord models
# under jarvis/assets/wakeword/ are NOT tracked here — that is a separate decision.
!jarvis/assets/vad/silero_vad.onnx
+# The word-agnostic openWakeWord feature backbones are deliberately BUNDLED and
+# shipped in-repo (jarvis/assets/__init__.py loads them for user-trained custom
+# wake models). Scoped to the exact files so nearby *.onnx (user-trained custom
+# wake models, Whisper cache) stay ignored. No branded hey_* model is tracked.
+!jarvis/assets/wakeword/melspectrogram.onnx
+!jarvis/assets/wakeword/embedding_model.onnx
# Audio-Blobs + Flight-Recorder-Traces
blobs/
diff --git a/jarvis/assets/wakeword/embedding_model.onnx b/jarvis/assets/wakeword/embedding_model.onnx
new file mode 100644
index 0000000000..afde53ef52
Binary files /dev/null and b/jarvis/assets/wakeword/embedding_model.onnx differ
diff --git a/jarvis/assets/wakeword/melspectrogram.onnx b/jarvis/assets/wakeword/melspectrogram.onnx
new file mode 100644
index 0000000000..a3a60354ee
Binary files /dev/null and b/jarvis/assets/wakeword/melspectrogram.onnx differ
diff --git a/tests/unit/assets/test_bundled_wakeword.py b/tests/unit/assets/test_bundled_wakeword.py
new file mode 100644
index 0000000000..3c9b91a243
--- /dev/null
+++ b/tests/unit/assets/test_bundled_wakeword.py
@@ -0,0 +1,20 @@
+"""The word-agnostic openWakeWord backbones must ship in a clean checkout, and
+ONLY those two — no branded hey_* model may ever be smuggled back in."""
+from pathlib import Path
+
+import jarvis.assets as assets
+
+
+def test_backbones_are_bundled_and_resolvable():
+ models = assets.bundled_wakeword_models()
+ assert models is not None, "backbones must be present in a clean checkout"
+ assert models["melspec"].is_file()
+ assert models["embedding"].is_file()
+
+
+def test_wakeword_dir_holds_only_word_agnostic_models():
+ d = Path(assets.__file__).resolve().parent / "wakeword"
+ onnx = sorted(p.name for p in d.glob("*.onnx"))
+ assert onnx == ["embedding_model.onnx", "melspectrogram.onnx"], (
+ f"only word-agnostic backbones allowed, found: {onnx}"
+ )