Refactor wake phrase handling: introduce REQUIRE_WAKE_WORD configuration, update documentation, and adjust assistant behavior for improved user experience.

This commit is contained in:
TheMajesticMagician
2026-10-25 22:48:37 -06:00
parent ca65670638
commit a8c7db9520
7 changed files with 84 additions and 54 deletions
+4 -2
View File
@@ -1,4 +1,5 @@
"""Bolt Assistant: say "Hey Bolt", ask, hear the answer.
"""Bolt Assistant: talk while the mic is open, hear the answer. (Setting
REQUIRE_WAKE_WORD=true puts "Hey Bolt" back in front of each request.)
python -m bolt_assistant listen on the default mic
python -m bolt_assistant --verbose also show what was heard but ignored
@@ -89,7 +90,8 @@ def main(argv=None) -> int:
return 0
if "--type" in argv: # the whole pipeline minus the microphone
print("Type what you'd say (including the wake phrase). Ctrl+C to quit.")
hint = " (including the wake phrase)" if assistant.wake_required else ""
print(f"Type what you'd say{hint}. Ctrl+C to quit.")
try:
while True:
assistant.heard(input("say> "))