Package com.oracle.bmc.aispeech.model
Class RealtimeParameters.Builder
- java.lang.Object
-
- com.oracle.bmc.aispeech.model.RealtimeParameters.Builder
-
- Enclosing class:
- RealtimeParameters
public static class RealtimeParameters.Builder extends Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RealtimeParameters
build()
RealtimeParameters.Builder
copy(RealtimeParameters model)
RealtimeParameters.Builder
customizations(List<CustomizationInference> customizations)
Array of customization objects.RealtimeParameters.Builder
encoding(String encoding)
Audio encoding to use - audio/raw;rate=16000 - audio/raw;rate=8000 - audio/raw;rate=8000;codec=mulaw - audio/raw;rate=8000;codec=alawRealtimeParameters.Builder
finalSilenceThresholdInMs(Integer finalSilenceThresholdInMs)
Silence threshold for Realtime Speech final results in milliseconds.RealtimeParameters.Builder
isAckEnabled(Boolean isAckEnabled)
Toggle for ack messages.RealtimeParameters.Builder
languageCode(String languageCode)
Locale value as per given in [https://datatracker.ietf.org/doc/html/rfc5646].RealtimeParameters.Builder
modelDomain(RealtimeParameters.ModelDomain modelDomain)
Model Domain.RealtimeParameters.Builder
partialSilenceThresholdInMs(Integer partialSilenceThresholdInMs)
Silence threshold for Realtime Speech partial results in milliseconds.RealtimeParameters.Builder
punctuation(RealtimeParameters.Punctuation punctuation)
Configure punctuations in the generated transcriptions.RealtimeParameters.Builder
shouldIgnoreInvalidCustomizations(Boolean shouldIgnoreInvalidCustomizations)
If set to true, the service will not fail connection attempt if it encounters any issues that prevent the loading of all specified user customizations.RealtimeParameters.Builder
stabilizePartialResults(RealtimeParameters.StabilizePartialResults stabilizePartialResults)
When enabled sets the amount of confidence required for latest tokens before returning them as part of a new partial result
-
-
-
Method Detail
-
encoding
public RealtimeParameters.Builder encoding(String encoding)
Audio encoding to use - audio/raw;rate=16000 - audio/raw;rate=8000 - audio/raw;rate=8000;codec=mulaw - audio/raw;rate=8000;codec=alaw- Parameters:
encoding
- the value to set- Returns:
- this builder
-
isAckEnabled
public RealtimeParameters.Builder isAckEnabled(Boolean isAckEnabled)
Toggle for ack messages.- Parameters:
isAckEnabled
- the value to set- Returns:
- this builder
-
partialSilenceThresholdInMs
public RealtimeParameters.Builder partialSilenceThresholdInMs(Integer partialSilenceThresholdInMs)
Silence threshold for Realtime Speech partial results in milliseconds.- Parameters:
partialSilenceThresholdInMs
- the value to set- Returns:
- this builder
-
finalSilenceThresholdInMs
public RealtimeParameters.Builder finalSilenceThresholdInMs(Integer finalSilenceThresholdInMs)
Silence threshold for Realtime Speech final results in milliseconds.- Parameters:
finalSilenceThresholdInMs
- the value to set- Returns:
- this builder
-
stabilizePartialResults
public RealtimeParameters.Builder stabilizePartialResults(RealtimeParameters.StabilizePartialResults stabilizePartialResults)
When enabled sets the amount of confidence required for latest tokens before returning them as part of a new partial result- Parameters:
stabilizePartialResults
- the value to set- Returns:
- this builder
-
modelDomain
public RealtimeParameters.Builder modelDomain(RealtimeParameters.ModelDomain modelDomain)
Model Domain.- Parameters:
modelDomain
- the value to set- Returns:
- this builder
-
languageCode
public RealtimeParameters.Builder languageCode(String languageCode)
Locale value as per given in [https://datatracker.ietf.org/doc/html/rfc5646].- en-US: English - United States - es-ES: Spanish - Spain - pt-BR: Portuguese - Brazil - en-GB: English - Great Britain - en-AU: English - Australia - en-IN: English - India - hi-IN: Hindi - India - fr-FR: French - France - de-DE: German - Germany - it-IT: Italian - Italy
- Parameters:
languageCode
- the value to set- Returns:
- this builder
-
shouldIgnoreInvalidCustomizations
public RealtimeParameters.Builder shouldIgnoreInvalidCustomizations(Boolean shouldIgnoreInvalidCustomizations)
If set to true, the service will not fail connection attempt if it encounters any issues that prevent the loading of all specified user customizations.Any invalid customizations will simply be ignored and connection will continue being established with the default base model and any remaining valid customizations. If set to false, if the service is unable to load any of the specified customizations, an error detailing why will be returned and the session will end.
- Parameters:
shouldIgnoreInvalidCustomizations
- the value to set- Returns:
- this builder
-
customizations
public RealtimeParameters.Builder customizations(List<CustomizationInference> customizations)
Array of customization objects.- Parameters:
customizations
- the value to set- Returns:
- this builder
-
punctuation
public RealtimeParameters.Builder punctuation(RealtimeParameters.Punctuation punctuation)
Configure punctuations in the generated transcriptions.Disabled by default. - NONE: No punctuation in the transcription response - SPOKEN: Punctuations in response only when verbally spoken - AUTO: Automatic punctuation in the response, spoken punctuations are disabled
- Parameters:
punctuation
- the value to set- Returns:
- this builder
-
build
public RealtimeParameters build()
-
copy
public RealtimeParameters.Builder copy(RealtimeParameters model)
-
-