pub struct ChatUpdate<'a> {
pub completion_id: &'a str,
pub extra_body: Option<Map<String, Value>>,
pub extra_query: HashMap<&'a str, &'a str>,
pub metadata: Option<HashMap<&'a str, &'a str>>,
}Expand description
Modify a stored chat completion.
Only Chat Completions that have been created
with the store parameter set to true can be modified. Currently, the only
supported modification is to update the metadata field.
Fields§
§completion_id: &'a strThe ID of the completion to update.
extra_body: Option<Map<String, Value>>Add additional JSON properties to the request
extra_query: HashMap<&'a str, &'a str>Add additional query parameters to the request
metadata: Option<HashMap<&'a str, &'a str>>Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format, and querying for objects via API or the dashboard.
Keys are strings with a maximum length of 64 characters. Values are strings with a maximum length of 512 characters.
Implementations§
Trait Implementations§
Source§impl<'a> Clone for ChatUpdate<'a>
impl<'a> Clone for ChatUpdate<'a>
Source§fn clone(&self) -> ChatUpdate<'a>
fn clone(&self) -> ChatUpdate<'a>
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<'a> Debug for ChatUpdate<'a>
impl<'a> Debug for ChatUpdate<'a>
Source§impl<'a> Default for ChatUpdate<'a>
impl<'a> Default for ChatUpdate<'a>
Source§fn default() -> ChatUpdate<'a>
fn default() -> ChatUpdate<'a>
Returns the “default value” for a type. Read more
Source§impl Post for ChatUpdate<'_>
impl Post for ChatUpdate<'_>
Source§impl PostNoStream for ChatUpdate<'_>
impl PostNoStream for ChatUpdate<'_>
type Response = ChatCompletion
Source§fn get_response_string(
&self,
base_url: &str,
key: &str,
) -> impl Future<Output = Result<String, OapiError>> + Send + Sync
fn get_response_string( &self, base_url: &str, key: &str, ) -> impl Future<Output = Result<String, OapiError>> + Send + Sync
Sends a POST request to the specified URL with the provided api-key.
fn get_response( &self, url: &str, key: &str, ) -> impl Future<Output = Result<Self::Response, OapiError>> + Send + Sync
Auto Trait Implementations§
impl<'a> Freeze for ChatUpdate<'a>
impl<'a> RefUnwindSafe for ChatUpdate<'a>
impl<'a> Send for ChatUpdate<'a>
impl<'a> Sync for ChatUpdate<'a>
impl<'a> Unpin for ChatUpdate<'a>
impl<'a> UnwindSafe for ChatUpdate<'a>
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