Search code examples
flutterflutter-dependenciesvoice-recognitionvoiceflutter-packages

Flutter: Voice Detection Trigger Phrase


I am currently using the speech_to_text package to add voice control to my Flutter app. This voice detection is triggered by a button click.

Is there any way to trigger the voice detection when the user says a certain phrase similiar to "Hey Google" instead of having to press the button every time? The library itself does not provide a way to add a "standby detection" mode and continous detection is not supported. Other ideas on how to circumnavigate this additional click are also welcome.

If your answer includes a library it would be great if it is free or has a free plan. This would really boost the user experience a lot. Thanks.


Solution

  • You could try to use this package: https://pub.dev/packages/picovoice_flutter

    They have a pretty detailed tutorial here: https://medium.com/picovoice/offline-speech-recognition-in-flutter-no-siri-no-google-and-no-its-not-speech-to-text-c960180e9239

    It is not a common feature, so I am afraid you are not going to find a lot of options, but the one above should do the trick