pub struct RealtimeServerEventConversationItemTruncated {
pub event_id: String,
pub item_id: String,
pub content_index: i64,
pub audio_end_ms: i64,
}
Expand description
Returned when an earlier assistant audio message item is truncated by the
client with a conversation.item.truncate
event. This event is used to
synchronize the server’s understanding of the audio with the client’s playback.
This action will truncate the audio and remove the server-side text transcript to ensure there is no text in the context that hasn’t been heard by the user.
Fields§
§event_id: String
The unique ID of the server event.
item_id: String
The ID of the assistant message item that was truncated.
content_index: i64
The index of the content part that was truncated.
audio_end_ms: i64
The duration up to which the audio was truncated, in milliseconds.
Implementations§
Source§impl RealtimeServerEventConversationItemTruncated
impl RealtimeServerEventConversationItemTruncated
Sourcepub fn builder() -> RealtimeServerEventConversationItemTruncatedBuilder<((), (), (), ())>
pub fn builder() -> RealtimeServerEventConversationItemTruncatedBuilder<((), (), (), ())>
Create a builder for building RealtimeServerEventConversationItemTruncated
.
On the builder, call .event_id(...)
, .item_id(...)
, .content_index(...)
, .audio_end_ms(...)
to set the values of the fields.
Finally, call .build()
to create the instance of RealtimeServerEventConversationItemTruncated
.
Trait Implementations§
Source§impl Clone for RealtimeServerEventConversationItemTruncated
impl Clone for RealtimeServerEventConversationItemTruncated
Source§fn clone(&self) -> RealtimeServerEventConversationItemTruncated
fn clone(&self) -> RealtimeServerEventConversationItemTruncated
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl<'de> Deserialize<'de> for RealtimeServerEventConversationItemTruncated
impl<'de> Deserialize<'de> for RealtimeServerEventConversationItemTruncated
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 RealtimeServerEventConversationItemTruncated
impl PartialEq for RealtimeServerEventConversationItemTruncated
Source§fn eq(&self, other: &RealtimeServerEventConversationItemTruncated) -> bool
fn eq(&self, other: &RealtimeServerEventConversationItemTruncated) -> bool
self
and other
values to be equal, and is used by ==
.