Class SpeechRecognitionAlternative
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel
public class SpeechRecognitionAlternative
extends com.ibm.cloud.sdk.core.service.model.GenericModel
-
Constructor Summary
Constructors Constructor Description SpeechRecognitionAlternative()
-
Method Summary
Modifier and Type Method Description Double
getConfidence()
Gets the confidence.List<SpeechTimestamp>
getTimestamps()
Gets the timestamps.String
getTranscript()
Gets the transcript.List<SpeechWordConfidence>
getWordConfidence()
Gets the wordConfidence.Methods inherited from class com.ibm.cloud.sdk.core.service.model.GenericModel
equals, hashCode, toString
-
Constructor Details
-
SpeechRecognitionAlternative
public SpeechRecognitionAlternative()
-
-
Method Details
-
getTranscript
Gets the transcript.A transcription of the audio.
- Returns:
- the transcript
-
getConfidence
Gets the confidence.A score that indicates the service's confidence in the transcript in the range of 0.0 to 1.0. The service returns a confidence score only for the best alternative and only with results marked as final.
- Returns:
- the confidence
-
getTimestamps
Gets the timestamps.Time alignments for each word from the transcript as a list of lists. Each inner list consists of three elements: the word followed by its start and end time in seconds, for example: `[["hello",0.0,1.2],["world",1.2,2.5]]`. Timestamps are returned only for the best alternative.
- Returns:
- the timestamps
-
getWordConfidence
Gets the wordConfidence.A confidence score for each word of the transcript as a list of lists. Each inner list consists of two elements: the word and its confidence score in the range of 0.0 to 1.0, for example: `[["hello",0.95],["world",0.866]]`. Confidence scores are returned only for the best alternative and only with results marked as final.
- Returns:
- the wordConfidence
-