pub struct CompletionChunk {
pub id: String,
pub model: String,
pub choices: Vec<ChoiceDelta>,
pub created: Option<i64>,
}Expand description
A chunk of a streaming completion response.
Fields§
§id: StringUnique response identifier
model: StringModel used for completion
choices: Vec<ChoiceDelta>List of choice deltas
created: Option<i64>Unix timestamp of creation
Trait Implementations§
Source§impl Clone for CompletionChunk
impl Clone for CompletionChunk
Source§fn clone(&self) -> CompletionChunk
fn clone(&self) -> CompletionChunk
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CompletionChunk
impl Debug for CompletionChunk
Source§impl<'de> Deserialize<'de> for CompletionChunk
impl<'de> Deserialize<'de> for CompletionChunk
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>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for CompletionChunk
impl PartialEq for CompletionChunk
Source§impl Serialize for CompletionChunk
impl Serialize for CompletionChunk
impl StructuralPartialEq for CompletionChunk
Auto Trait Implementations§
impl Freeze for CompletionChunk
impl RefUnwindSafe for CompletionChunk
impl Send for CompletionChunk
impl Sync for CompletionChunk
impl Unpin for CompletionChunk
impl UnwindSafe for CompletionChunk
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more