Passer au contenu

@capgo/capacitor-speech-recognition

Capacitor plugin for comprehensive on-device speech recognition with live partial results.

Capacitor plugin for comprehensive on-device speech recognition with live partial results.

  • available - Checks whether the native speech recognition service is usable on the current device.
  • isOnDeviceRecognitionAvailable - Checks whether the platform’s newer on-device recognition path is available for the selected locale.
  • start - Begins capturing audio and transcribing speech.
  • stop - Stops listening and tears down native resources.
MethodDescription
availableChecks whether the native speech recognition service is usable on the current device.
isOnDeviceRecognitionAvailableChecks whether the platform’s newer on-device recognition path is available for the selected locale.
startBegins capturing audio and transcribing speech.
stopStops listening and tears down native resources.
forceStopForce stops the current session.
getLastPartialResultGets the last cached partial transcription result.
setPTTStateUpdates the current push-to-talk button state.
getSupportedLanguagesGets the locales supported by the underlying recognizer.
isListeningReturns whether the plugin is actively listening for speech.
checkPermissionsGets the current permission state.
requestPermissionsRequests the microphone + speech recognition permissions.
getPluginVersionReturns the native plugin version bundled with this package.
addListenerListen for segmented session completion events (Android only).
addListenerListen for segmented recognition results (Android only).
addListenerListen for partial transcription updates emitted while partialResults is enabled.
addListenerListen for changes to the native listening state.
addListenerListen for recognition errors.
addListenerListen for the recognizer becoming ready for another session.
removeAllListenersRemoves every registered listener.

This reference is synced from src/definitions.ts in capacitor-speech-recognition.