Skip to main content

Speech recognition results

Speech recognition results are added to $request.rawRequest. The data is available in the $request.rawRequest.data field.

Example:

{
"cause": "OK",
"text": "How are you?"
}

Here:

  • cause is the recognition result. Possible values:
    • "OK": the speech was successfully recognized.
    • "NO_INPUT": speech recognition failed.
  • text is the speech text. The field is present if cause is "OK".

User request data

The results may also contain additional data about the user’s request in the $request.rawRequest.data.propertiesResponse.result field.

Example:

{
"recognition_result": {
"start_time": "0.510s",
"end_time": "2.550s",
"gender_identification_result": {
"male_proba": 0.991876,
"female_proba": 0.008123994
}
},
"is_final": true
}

User request data is available for the following providers:

  • Yandex SpeechKit v2
  • Yandex SpeechKit v3
  • Tinkoff VoiceKit
  • 3iTech

For example, you can get:

  • Hypotheses about user gender in Tinkoff Voicekit.
  • The list of recognized languages and their probability in Yandex SpeechKit v3.

Supported fields

$request.rawRequest.data.propertiesResponse.result supports a limited number of fields:

  • chunks:
    • alternatives

      • text
      • confidence
    • final

    • endOfUtterance

In the Yandex SpeechKit v2 documentation, you can view the description of these fields and learn about the conditions under which they are added.

info
  • Some data is added only if additional settings are specified for the ASR provider. To specify the settings, use the $dialer.setAsrProperty method.
  • If you want to use data that is not supported in $request.rawRequest, please contact our support team: support@just-ai.com.