openai_struct/models/
realtime_server_event_input_audio_buffer_speech_stopped.rs

1/*
2 * OpenAI API
3 *
4 * The OpenAI REST API. Please see pub https://platform.openai.com/docs/api-reference for more details.
5 *
6 * OpenAPI spec pub version: 2.3.0
7 *
8 * Generated pub by: https://github.com/swagger-api/swagger-codegen.git
9 */
10
11/// pub RealtimeServerEventInputAudioBufferSpeechStopped : Returned in `server_vad` mode when the server detects the end of speech in  the audio buffer. The server will also send an `conversation.item.created`  event with the user message item that is created from the audio buffer.
12
13#[allow(unused_imports)]
14use serde_json::Value;
15
16#[derive(Debug, Serialize, Deserialize)]
17pub struct RealtimeServerEventInputAudioBufferSpeechStopped {
18    /// Milliseconds since the session started when speech stopped. This will  correspond to the end of audio sent to the model, and thus includes the  `min_silence_duration_ms` configured in the Session.
19    #[serde(rename = "audio_end_ms")]
20    pub audio_end_ms: i32,
21    /// The unique ID of the server event.
22    #[serde(rename = "event_id")]
23    pub event_id: String,
24    /// The ID of the user message item that will be created.
25    #[serde(rename = "item_id")]
26    pub item_id: String,
27    /// The event type, must be `input_audio_buffer.speech_stopped`.
28    #[serde(rename = "type")]
29    pub _type: String,
30}