pub enum SemanticRepresentation {
Symmetric,
Document,
Query,
}
Expand description
Allows you to choose a semantic representation fitting for your use case.
Variants§
Symmetric
Useful for comparing prompts to each other, in use cases such as clustering, classification,
similarity, etc. Symmetric
embeddings are intended to be compared with other Symmetric
embeddings.
Document
Document
and Query
are used together in use cases such as search where you want to
compare shorter queries against larger documents. Document
embeddings are optimized for
larger pieces of text to compare queries against.
Query
Document
and Query
are used together in use cases such as search where you want to
compare shorter queries against larger documents. Query
embeddings are optimized for
shorter texts, such as questions or keywords.
Trait Implementations§
Source§impl Debug for SemanticRepresentation
impl Debug for SemanticRepresentation
Auto Trait Implementations§
impl Freeze for SemanticRepresentation
impl RefUnwindSafe for SemanticRepresentation
impl Send for SemanticRepresentation
impl Sync for SemanticRepresentation
impl Unpin for SemanticRepresentation
impl UnwindSafe for SemanticRepresentation
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>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more