Enable voice-to-text functionality for a Naia Agent Studio agent in the mobile client
The following steps show how to enable voice-to-text for a Naia Agent Studio agent in the mobile client. Voice-to-text lets your agent capture spoken input, enabling faster, hands-free, and more natural interactions in mobile scenarios, especially useful in field scenarios, accessibility use cases, or when typing is impractical.
The process shown here reflects the standard pattern for activating mobile agent features by entering custom configurations in the Custom Config tab. You can use this same approach to enable additional agent capabilities for launchpad agents in the mobile client.
Prerequisites
-
You have configured an agent and assigned it to a launchpad.
-
You have configured a mobile client.
-
In Plugins, you have added the
cordova-plugin-speechrecognitionplugin.
Procedure
-
In the Custom Config tab, to enable mobile voice-to-text speech recognition and usage, enter the following custom XML into the editor with the appropriate platform tags depending on the mobile operating system:
-
For Android:
<platform name="android"> <uses-permission android:name="android.permission.RECORD_AUDIO" /> </platform> -
For iOS:
<platform name="ios"> <edit-config target="NSSpeechRecognitionUsageDescription" file="*-Info.plist" mode="merge"> <string>Speech Recognition</string></edit-config> </platform>
-
If you have already generated the ZIP file for the mobile client application,
you can alternatively extract the config.xml file and enter the platform-dependent
custom XML entries for voice-to-text speech recognition and usage in the config.xml
file, and recompress the ZIP file.
|
Next steps
-
Upload the ZIP file in the Neptune Mobile Build Service in Neptune DXP Portal to generate and deploy the mobile app.