pub struct RealtimeTranscriptionSessionCreateResponse {
pub client_secret: RealtimeTranscriptionSessionCreateResponseClientSecret,
pub modalities: Option<Vec<RealtimeTranscriptionSessionCreateResponseModality>>,
pub input_audio_format: Option<String>,
pub input_audio_transcription: Option<RealtimeTranscriptionSessionCreateResponseInputAudioTranscription>,
pub turn_detection: Option<RealtimeTranscriptionSessionCreateResponseTurnDetection>,
}
Expand description
A new Realtime transcription session configuration.
When a session is created on the server via REST API, the session object also contains an ephemeral key. Default TTL for keys is 10 minutes. This property is not present when a session is updated via the WebSocket API.
Fields§
§client_secret: RealtimeTranscriptionSessionCreateResponseClientSecret
Ephemeral key returned by the API. Only present when the session is created on the server via REST API.
modalities: Option<Vec<RealtimeTranscriptionSessionCreateResponseModality>>
The set of modalities the model can respond with. To disable audio, set this to [“text”].
input_audio_format: Option<String>
The format of input audio. Options are pcm16
, g711_ulaw
, or g711_alaw
.
input_audio_transcription: Option<RealtimeTranscriptionSessionCreateResponseInputAudioTranscription>
Configuration of the transcription model.
turn_detection: Option<RealtimeTranscriptionSessionCreateResponseTurnDetection>
Configuration for turn detection. Can be set to null
to turn off. Server
VAD means that the model will detect the start and end of speech based on
audio volume and respond at the end of user speech.
Implementations§
Source§impl RealtimeTranscriptionSessionCreateResponse
impl RealtimeTranscriptionSessionCreateResponse
Sourcepub fn builder() -> RealtimeTranscriptionSessionCreateResponseBuilder<((), (), (), (), ())>
pub fn builder() -> RealtimeTranscriptionSessionCreateResponseBuilder<((), (), (), (), ())>
Create a builder for building RealtimeTranscriptionSessionCreateResponse
.
On the builder, call .client_secret(...)
, .modalities(...)
(optional), .input_audio_format(...)
(optional), .input_audio_transcription(...)
(optional), .turn_detection(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of RealtimeTranscriptionSessionCreateResponse
.
Trait Implementations§
Source§impl Clone for RealtimeTranscriptionSessionCreateResponse
impl Clone for RealtimeTranscriptionSessionCreateResponse
Source§fn clone(&self) -> RealtimeTranscriptionSessionCreateResponse
fn clone(&self) -> RealtimeTranscriptionSessionCreateResponse
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl<'de> Deserialize<'de> for RealtimeTranscriptionSessionCreateResponse
impl<'de> Deserialize<'de> for RealtimeTranscriptionSessionCreateResponse
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl PartialEq for RealtimeTranscriptionSessionCreateResponse
impl PartialEq for RealtimeTranscriptionSessionCreateResponse
Source§fn eq(&self, other: &RealtimeTranscriptionSessionCreateResponse) -> bool
fn eq(&self, other: &RealtimeTranscriptionSessionCreateResponse) -> bool
self
and other
values to be equal, and is used by ==
.