pub enum PromptGranularity {
Auto,
Word,
Sentence,
Paragraph,
}
Expand description
At which granularity should the target be explained in terms of the prompt. If you choose, for example, PromptGranularity::Sentence then we report the importance score of each sentence in the prompt towards generating the target output. The default is PromptGranularity::Auto which means we will try to find the granularity that brings you closest to around 30 explanations. For large prompts, this would likely be sentences. For short prompts this might be individual words or even tokens.
Variants§
Auto
Let the system decide which granularity is most suitable for the given input. This will result
Word
Sentence
Paragraph
Trait Implementations§
source§impl Clone for PromptGranularity
impl Clone for PromptGranularity
source§fn clone(&self) -> PromptGranularity
fn clone(&self) -> PromptGranularity
Returns a copy 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 Default for PromptGranularity
impl Default for PromptGranularity
source§fn default() -> PromptGranularity
fn default() -> PromptGranularity
Returns the “default value” for a type. Read more
source§impl PartialEq<PromptGranularity> for PromptGranularity
impl PartialEq<PromptGranularity> for PromptGranularity
source§fn eq(&self, other: &PromptGranularity) -> bool
fn eq(&self, other: &PromptGranularity) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for PromptGranularity
impl Serialize for PromptGranularity
impl Copy for PromptGranularity
impl StructuralPartialEq for PromptGranularity
Auto Trait Implementations§
impl RefUnwindSafe for PromptGranularity
impl Send for PromptGranularity
impl Sync for PromptGranularity
impl Unpin for PromptGranularity
impl UnwindSafe for PromptGranularity
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<R, P> ReadPrimitive<R> for Pwhere
R: Read + ReadEndian<P>,
P: Default,
impl<R, P> ReadPrimitive<R> for Pwhere R: Read + ReadEndian<P>, P: Default,
source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian()
.