pub struct FloppyBuilder { /* private fields */ }Expand description
Builder for a MemoryStore with explicit configuration (no environment variables).
Implementations§
Source§impl FloppyBuilder
impl FloppyBuilder
pub fn new(db_path: impl Into<String>, session_id: impl Into<String>) -> Self
pub fn from_paths(paths: &FloppyPaths, session_id: impl Into<String>) -> Self
pub fn vector_type(self, vector_type: VectorType) -> Self
pub fn dimensions(self, dimensions: u32) -> Self
pub fn top_k(self, top_k: u32) -> Self
pub fn learning_rate(self, learning_rate: f64) -> Self
pub fn decay_rate(self, decay_rate: f64) -> Self
Sourcepub fn apply_migrations(self, apply: bool) -> Self
pub fn apply_migrations(self, apply: bool) -> Self
Skip floppy migrations in MemoryStore::init when the host already applied them.
Sourcepub fn embed(self, embed: EmbedFn) -> Self
pub fn embed(self, embed: EmbedFn) -> Self
Custom embedder; mutually exclusive with Self::fastembed.
Sourcepub fn noop_embed(self) -> Self
pub fn noop_embed(self) -> Self
Zero-vector embedder for read-only inspection without a local model.
pub fn fastembed(self, _options: FastEmbedOptions) -> Result<Self>
pub fn build(self) -> Result<MemoryStore>
Auto Trait Implementations§
impl !RefUnwindSafe for FloppyBuilder
impl !UnwindSafe for FloppyBuilder
impl Freeze for FloppyBuilder
impl Send for FloppyBuilder
impl Sync for FloppyBuilder
impl Unpin for FloppyBuilder
impl UnsafeUnpin for FloppyBuilder
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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