pub struct SystemOne<'a> { /* private fields */ }Expand description
A request under construction.
Implementations§
Source§impl<'a> SystemOne<'a>
impl<'a> SystemOne<'a>
Sourcepub fn model(self, model: impl Into<String>) -> Self
pub fn model(self, model: impl Into<String>) -> Self
Name a model or a configured alias. The service’s default applies otherwise.
Sourcepub fn calibration(self, temperature: f64) -> Self
pub fn calibration(self, temperature: f64) -> Self
Scale the label logits before they are normalised. Above 1 flattens, below 1 sharpens.
Sourcepub fn noul(self, id: impl Into<String>, question: impl Into<String>) -> Self
pub fn noul(self, id: impl Into<String>, question: impl Into<String>) -> Self
How likely the answer to question is yes.
Sourcepub fn choice<S: AsRef<str>>(
self,
id: impl Into<String>,
question: impl Into<String>,
options: impl IntoIterator<Item = S>,
) -> Self
pub fn choice<S: AsRef<str>>( self, id: impl Into<String>, question: impl Into<String>, options: impl IntoIterator<Item = S>, ) -> Self
One of options.
Sourcepub fn choice_of<S: AsRef<str>>(
self,
id: impl Into<String>,
options: impl IntoIterator<Item = S>,
) -> Self
pub fn choice_of<S: AsRef<str>>( self, id: impl Into<String>, options: impl IntoIterator<Item = S>, ) -> Self
One of options, where the options speak for themselves.
Sourcepub fn score(
self,
id: impl Into<String>,
question: impl Into<String>,
levels: impl Into<Levels>,
) -> Self
pub fn score( self, id: impl Into<String>, question: impl Into<String>, levels: impl Into<Levels>, ) -> Self
A position on a rubric: 5 for five generated levels, or a list of level texts.
Sourcepub fn body(&self) -> &SystemOneRequest
pub fn body(&self) -> &SystemOneRequest
The request as it will be sent. Useful for logging and for testing a builder chain without a server.
pub async fn send(self) -> Result<Answers, Error>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for SystemOne<'a>
impl<'a> !UnwindSafe for SystemOne<'a>
impl<'a> Freeze for SystemOne<'a>
impl<'a> Send for SystemOne<'a>
impl<'a> Sync for SystemOne<'a>
impl<'a> Unpin for SystemOne<'a>
impl<'a> UnsafeUnpin for SystemOne<'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