Skip to content

Commit

Permalink
chore: removed unneeded TODO
Browse files Browse the repository at this point in the history
  • Loading branch information
mfkrause committed Nov 22, 2024
1 parent 4615f5a commit 18b2b99
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions android/src/main/java/com/voicekit/VoiceKitService.kt
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,11 @@ class VoiceKitService(private val context: ReactApplicationContext) {
}

if (options.hasKey("mode") && (options.getString("mode") == "continuous" || options.getString("mode") == "continuous-and-stop")) {
// TODO: On Android 13+, we might be able to use a custom audio source to improve continuous mode
putExtra(RecognizerIntent.EXTRA_SPEECH_INPUT_COMPLETE_SILENCE_LENGTH_MILLIS, 600000)
putExtra(RecognizerIntent.EXTRA_SPEECH_INPUT_MINIMUM_LENGTH_MILLIS, 600000)
putExtra(RecognizerIntent.EXTRA_SPEECH_INPUT_POSSIBLY_COMPLETE_SILENCE_LENGTH_MILLIS, 600000)
// 60s / 1 minute matches the maximum duration of the iOS SFSpeechRecognizer
// see https://developer.apple.com/documentation/speech/sfspeechrecognizer
putExtra(RecognizerIntent.EXTRA_SPEECH_INPUT_COMPLETE_SILENCE_LENGTH_MILLIS, 60000)
putExtra(RecognizerIntent.EXTRA_SPEECH_INPUT_MINIMUM_LENGTH_MILLIS, 60000)
putExtra(RecognizerIntent.EXTRA_SPEECH_INPUT_POSSIBLY_COMPLETE_SILENCE_LENGTH_MILLIS, 60000)
}
}

Expand Down

0 comments on commit 18b2b99

Please sign in to comment.