pub struct Message {
pub id: String,
pub status: MessageStatus,
pub role: MessageRole,
pub content: Vec<MessageContent>,
pub phase: Option<MessagePhase>,
}Available on crate feature
response-types only.Fields§
§id: StringThe unique ID of the message.
status: MessageStatusThe status of item. One of in_progress, completed, or incomplete. Populated when items are
returned via API.
role: MessageRoleThe role of the message. One of unknown, user, assistant, system, critic,
discriminator, developer, or tool.
content: Vec<MessageContent>The content of the message.
phase: Option<MessagePhase>Labels an assistant message as intermediate commentary (commentary) or the final
answer (final_answer). Not used for user messages.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Message
impl<'de> Deserialize<'de> for Message
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
impl StructuralPartialEq for Message
Auto Trait Implementations§
impl Freeze for Message
impl RefUnwindSafe for Message
impl Send for Message
impl Sync for Message
impl Unpin for Message
impl UnsafeUnpin for Message
impl UnwindSafe for Message
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