-
-
Notifications
You must be signed in to change notification settings - Fork 12
feat: ww verifier #341
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: ww verifier #341
Conversation
|
Caution Review failedThe pull request is closed. WalkthroughAdds a HotWordVerifier abstract class and verifier plugin support: new plugin enum entries, discovery and loader functions for verifier plugins, and a type annotation change for HotWordEngine.update(chunk: bytes). Changes
Sequence DiagramsequenceDiagram
participant Client
participant WakewordsModule
participant EntryPointRegistry
participant VerifierPlugin as HotWordVerifier
Client->>WakewordsModule: find_wake_word_verifier_plugins()
WakewordsModule->>EntryPointRegistry: query 'opm.wake_word.verifier'
EntryPointRegistry-->>WakewordsModule: {name: entrypoint, ...}
WakewordsModule-->>Client: list of verifiers
Client->>WakewordsModule: load_wake_word_verifier_plugin(module_name)
WakewordsModule->>EntryPointRegistry: load entrypoint
EntryPointRegistry-->>VerifierPlugin: Type[HotWordVerifier]
WakewordsModule-->>Client: verifier class
Client->>VerifierPlugin: verify(chunk: bytes)
VerifierPlugin-->>Client: bool
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 inconclusive)
✅ Passed checks (1 passed)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
ovos_plugin_manager/templates/hotwords.py(3 hunks)ovos_plugin_manager/utils/__init__.py(2 hunks)ovos_plugin_manager/wakewords.py(3 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
ovos_plugin_manager/wakewords.py (2)
ovos_plugin_manager/templates/hotwords.py (2)
HotWordEngine(21-109)HotWordVerifier(112-122)ovos_plugin_manager/utils/__init__.py (3)
find_plugins(144-173)PluginTypes(51-95)load_plugin(244-262)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: unit_tests (3.11)
- GitHub Check: unit_tests (3.10)
🔇 Additional comments (8)
ovos_plugin_manager/utils/__init__.py (2)
71-71: LGTM! New plugin type follows the existing pattern.The WAKEWORD_VERIFIER plugin type is correctly defined and follows the established naming convention.
118-118: LGTM! Config type correctly mirrors the plugin type.The WAKEWORD_VERIFIER config type follows the established pattern of adding
.configsuffix to the corresponding plugin type.ovos_plugin_manager/templates/hotwords.py (2)
2-4: LGTM! Imports support improved typing and existing functionality.The typing imports enhance type safety for the new HotWordVerifier class and updated method signatures, while the Configuration import supports the existing HotWordEngine initialization.
88-88: LGTM! Type annotation improves clarity.Adding the
bytestype annotation to thechunkparameter improves type safety and aligns with the method's docstring.ovos_plugin_manager/wakewords.py (4)
4-4: LGTM! Type import supports improved return type annotations.The
Typeimport is used appropriately in the return type annotations for plugin loading functions.
9-9: LGTM! Import supports verifier plugin loading.The
HotWordVerifierimport is correctly added to support the new verifier plugin functionality.
22-22: LGTM! Return type annotation improves type safety.The
Type[HotWordEngine]annotation accurately documents that this function returns an uninstantiated class.
32-48: LGTM! Verifier plugin functions follow established patterns.The new
find_wake_word_verifier_plugins()andload_wake_word_verifier_plugin()functions correctly mirror the existing wake word plugin functions, using the appropriateWAKEWORD_VERIFIERplugin type and return types.
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
* feat: ww verifier OpenVoiceOS/ovos-plugin-manager#341 * Update ovos_vad_plugin_silero/__init__.py Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
* fix: requirements.txt (#14) * fix: requirements.txt allow newer onnxruntime versions * Update requirements.txt * Increment Version to 0.0.6a1 * Update Changelog * feat: ww verifier (#16) * feat: ww verifier OpenVoiceOS/ovos-plugin-manager#341 * Update ovos_vad_plugin_silero/__init__.py Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * Increment Version to 0.1.0a1 * Update Changelog --------- Co-authored-by: JarbasAI <[email protected]> Co-authored-by: JarbasAl <[email protected]> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Summary by CodeRabbit
New Features
Improvements