voice-overlay-ios
Voice overlay helps you turn your user's voice into text, providing a polished UX while handling for you the necessary permissions.
It uses internally the native SFSpeechRecognizer in order to perform the speech to text conversion.
Demo
You can clone and run the Demo project by doing pod install
and then running the project
Installation
CocoaPods
InstantSearchVoiceOverlay
is available through CocoaPods. To install
it, add the following line to your Podfile:
Carthage
Carthage is a simple, decentralized dependency manager for Cocoa.
To install InstantSearchVoiceOverlay, add the following line to your Cartfile:
Usage
- In
Info.plist
, add these 2 string properties along with the description
Privacy - Microphone Usage Description
with a description like:Need the mic for audio to text
Privacy - Speech Recognition Usage Description
some description like:Need the speech recognition capabilities for searching tags

- Start the Voice Overlay and listen to the text output:
Customization
You can customize your voice overlay by modifying the settings
property of the voiceOverlayController:
Delegate
Optionally, to listen to text and error events, you can conform to the method of the VoiceOverlayDelegate
protocol.
How it handles when Permissions are missing
When there are missing permissions, the voice overlay will guide the user to the correct section of the settings app.

Result Screen (Beta)

The result screen appears when showResultScreen
is set to true.
The widget provides a resultScreenHandler
for when the result screen is dismissed (provided the "Start again" button is not clicked). The handler provides the text that has been set in resultScreenText
beforehand.