flutter_native_speech_to_text 1.2.0
flutter_native_speech_to_text: ^1.2.0 copied to clipboard
A Flutter plugin for native speech-to-text using Android's RecognizerIntent, Apple's Speech framework on iOS and macOS, and the Web Speech API on web. Windows and Linux fail safely.
1.2.0 #
- Added iOS and macOS support using Apple's Speech framework (
SFSpeechRecognizer), shared between both platforms. The previous iOS stub is replaced. - Apple platforms do not support Bengali;
listen()throwsLANGUAGE_NOT_SUPPORTEDfor unsupported languages. - Added
FlutterNativeSpeechToText.isLanguageSupported(language)on every platform. - Added Windows and Linux native stubs: they never crash,
isAvailable()andisLanguageSupported()returnfalse, andlisten()/stop()/cancel()fail withPLATFORM_NOT_SUPPORTED. - Includes the web fixes from 1.1.1 below.
1.1.1 #
- Web:
listen()now completes as soon as the browser reports an error, instead of waiting for an end event that Safari may never send. - Web:
stop()falls back to the latest result if the browser does not end the session within three seconds. - Web: Brave is detected, since it blocks the speech service.
isAvailable()returnsfalseandlisten()throwsNO_RECOGNIZERwith an explanatory message. - Web: new
SERVICE_NOT_ALLOWEDerror code, separate fromPERMISSION_DENIED, for browsers that block their speech service (for example Safari when the requested language is not installed for Dictation).
1.1.0 #
- Added web support using the browser's Web Speech API (
SpeechRecognition/webkitSpeechRecognition), exposed through the existinglisten,stop,cancelandisAvailableAPI. - New error codes on web:
PERMISSION_DENIED,NO_MICROPHONE,NETWORK,LANGUAGE_NOT_SUPPORTED. - Minimum SDK raised to Dart 3.4 / Flutter 3.22.
1.0.0 #
- Initial release of the plugin.
- Speech recognition using Android's native
ACTION_RECOGNIZE_SPEECHIntent. - Configurable parameters for
RecognizerIntentextras:languageModel(free form or web search)languageandlanguagePreferenceprompt,maxResultspartialResults,confidenceScores- Speech silence length limits (
speechInputMinimumLengthMillis,speechInputCompleteSilenceLengthMillis,speechInputPossiblyCompleteSilenceLengthMillis)
- Availability check with
FlutterNativeSpeechToText.isAvailable(). - Stop and cancel session controls.
- iOS support scaffold: the iOS implementation is a safe stub that never crashes.
isAvailable()returnsfalse.listen()/stop()/cancel()throwSpeechToTextExceptionwith codePLATFORM_NOT_SUPPORTED, so host apps can display and log the error.
- Complete example application demonstrating integration.