Audio to Text (FR)
Audio to Text (FR)
mobile:audio:text
Purpose
Converts audio to text by applying powerful neural network models. It accepts an audio file that may be recorded from a device and creates a text file that contains the textual translation of the audio file.
Parameters
Name |
Data Type |
Possible Values |
Default Values |
Description |
---|---|---|---|---|
deviceAudio |
String |
|
|
The URL to the audio file of the device (as, for example, returned by the start audio recording function). |
key |
Path |
PUBLIC: PRIVATE: |
|
Indicates the repository key of an audio file. |
language |
String |
us-english (US English) |
US English |
The supported Audio file languages. |
rate |
String |
broad (Broad) |
Broad |
Indicates the sampling rate of the audio recording |
profile |
String |
performance |
performance |
Profile of the NLP network |
phrase |
String |
|
|
Provides a list of phrases for speech-to-text library to use to avoid confusion. For example, provide the words:‘two’ and ‘four’ to avoid confusion with ‘to’ and ‘for’. |
Return Value
None
Exceptions
None
Examples
Java sample
Map<String, Object> params1 = new HashMap<>();
params1.put("deviceAudio", "");
params1.put("key", "PUBLIC:");
params1.put("language", "chinese");
params1.put("rate", "broad");
params1.put("profile", "accuracy");
Object result1 = driver.executeScript("mobile:audio:text", params1);