public class RecognizeOptions extends Object
SpeechToText
service.Constructor and Description |
---|
RecognizeOptions() |
Modifier and Type | Method and Description |
---|---|
RecognizeOptions |
contentType(String contentType)
The format of the audio data specified as one of the following values:
audio/flac for Free Lossless Audio Codec (FLAC)
audio/l16 for Linear 16-bit Pulse-Code Modulation (PCM)
audio/wav for Waveform Audio File Format (WAV)
audio/ogg;codecs=opus for Ogg format files that use the opus codec
|
RecognizeOptions |
continuous(Boolean continuous)
If true, multiple final results that represent multiple consecutive phrases separated by pauses
are returned.
|
String |
getContentType()
Gets the content type.
|
Boolean |
getContinuous()
Gets the continuous.
|
Integer |
getInactivityTimeout()
Gets the inactivity timeout.
|
Boolean |
getInterimResults()
Gets the interim results.
|
String[] |
getKeywords()
Gets the keywords.
|
Double |
getKeywordsThreshold()
Gets the keywords threshold.
|
Integer |
getMaxAlternatives()
Gets the max alternatives.
|
String |
getModel()
Gets the model.
|
String |
getSessionId()
Gets the session id.
|
Boolean |
getTimestamps()
Gets the timestamps.
|
Double |
getWordAlternativesThreshold()
Gets the word alternatives threshold.
|
Boolean |
getWordConfidence()
Gets the word confidence.
|
RecognizeOptions |
inactivityTimeout(Integer inactivityTimeout)
Inactivity timeout.
|
RecognizeOptions |
interimResults(Boolean interimResults)
If true, the service sends interim results for the transcription.
|
RecognizeOptions |
keywords(String[] keywords)
Specifies an array of keyword strings to be matched in the input audio.
|
RecognizeOptions |
keywordsThreshold(Double keywordsThreshold)
Specifies a minimum level of confidence that the service must have to report a matching keyword
in the input audio.
|
RecognizeOptions |
maxAlternatives(Integer maxAlternatives)
Maximum number of alternative transcripts returned.
|
RecognizeOptions |
model(String model)
Sets the model name used for the recognition.
|
RecognizeOptions |
session(SpeechSession session)
Sets the session id.
|
RecognizeOptions |
sessionId(String sessionId)
Sets session id.
|
RecognizeOptions |
timestamps(Boolean timestamps)
If true, time alignment for each word is returned.
|
RecognizeOptions |
wordAlternativesThreshold(Double wordAlternativesThreshold)
Specifies a minimum level of confidence that the service must have to report a hypothesis for a
word from the input audio.
|
RecognizeOptions |
wordConfidence(Boolean wordConfidence)
If true, confidence measure per word is returned if available.
|
public RecognizeOptions continuous(Boolean continuous)
continuous
- the continuouspublic String getContentType()
public Boolean getContinuous()
public Integer getInactivityTimeout()
public Boolean getInterimResults()
public String[] getKeywords()
public Double getKeywordsThreshold()
public Integer getMaxAlternatives()
public String getModel()
public String getSessionId()
public Boolean getTimestamps()
public Double getWordAlternativesThreshold()
public Boolean getWordConfidence()
public RecognizeOptions inactivityTimeout(Integer inactivityTimeout)
inactivityTimeout
- the inactivity timeoutpublic RecognizeOptions interimResults(Boolean interimResults)
interimResults
- the interim resultspublic RecognizeOptions keywords(String[] keywords)
keywords
- the keywordspublic RecognizeOptions keywordsThreshold(Double keywordsThreshold)
keywordsThreshold
- the keywords thresholdpublic RecognizeOptions maxAlternatives(Integer maxAlternatives)
maxAlternatives
- the max alternativespublic RecognizeOptions model(String model)
model
- the modelpublic RecognizeOptions session(SpeechSession session)
session
- the SpeechSession
public RecognizeOptions sessionId(String sessionId)
sessionId
- the session idpublic RecognizeOptions timestamps(Boolean timestamps)
timestamps
- the timestampspublic RecognizeOptions wordAlternativesThreshold(Double wordAlternativesThreshold)
wordAlternativesThreshold
- the wordAalternatives thresholdpublic RecognizeOptions contentType(String contentType)
audio/flac
for Free Lossless Audio Codec (FLAC)audio/l16
for Linear 16-bit Pulse-Code Modulation (PCM)audio/wav
for Waveform Audio File Format (WAV)audio/ogg;codecs=opus
for Ogg format files that use the opus codeccontentType
- the content typepublic RecognizeOptions wordConfidence(Boolean wordConfidence)
wordConfidence
- the word confidenceCopyright © 2015–2016. All rights reserved.