pub struct TokenLogProb {
pub token: String,
pub logprob: f32,
pub top_logprobs: Vec<TopLogProb>,
pub bytes: Option<Vec<u32>>,
}Expand description
Token log probability.
Fields§
§token: StringThe token.
logprob: f32The log probability of returning this token.
top_logprobs: Vec<TopLogProb>An array of the most likely tokens to return at this token position.
bytes: Option<Vec<u32>>The ASCII encoding of the output character.
Trait Implementations§
Source§impl Clone for TokenLogProb
impl Clone for TokenLogProb
Source§fn clone(&self) -> TokenLogProb
fn clone(&self) -> TokenLogProb
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 TokenLogProb
impl Debug for TokenLogProb
Source§impl Default for TokenLogProb
impl Default for TokenLogProb
Source§fn default() -> TokenLogProb
fn default() -> TokenLogProb
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for TokenLogProb
impl<'de> Deserialize<'de> for TokenLogProb
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 TokenLogProb
impl PartialEq for TokenLogProb
Source§impl Serialize for TokenLogProb
impl Serialize for TokenLogProb
impl StructuralPartialEq for TokenLogProb
Auto Trait Implementations§
impl Freeze for TokenLogProb
impl RefUnwindSafe for TokenLogProb
impl Send for TokenLogProb
impl Sync for TokenLogProb
impl Unpin for TokenLogProb
impl UnwindSafe for TokenLogProb
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