pub struct Models<'a> { /* private fields */ }Expand description
Access model endpoints.
API reference: https://platform.openai.com/docs/api-reference/models
Implementations§
Source§impl<'a> Models<'a>
impl<'a> Models<'a>
Sourcepub async fn list(&self) -> Result<ModelList, OpenAIError>
pub async fn list(&self) -> Result<ModelList, OpenAIError>
List available models.
GET /models
Sourcepub async fn retrieve(&self, model: &str) -> Result<Model, OpenAIError>
pub async fn retrieve(&self, model: &str) -> Result<Model, OpenAIError>
Retrieve a model by ID.
GET /models/{model}
Sourcepub async fn delete(&self, model: &str) -> Result<ModelDeleted, OpenAIError>
pub async fn delete(&self, model: &str) -> Result<ModelDeleted, OpenAIError>
Delete a fine-tuned model.
DELETE /models/{model}
Auto Trait Implementations§
impl<'a> Freeze for Models<'a>
impl<'a> !RefUnwindSafe for Models<'a>
impl<'a> Send for Models<'a>
impl<'a> Sync for Models<'a>
impl<'a> Unpin for Models<'a>
impl<'a> UnsafeUnpin for Models<'a>
impl<'a> !UnwindSafe for Models<'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