pub struct MemvidStoreBuilder { /* private fields */ }Expand description
Builder for MemvidStore.
Implementations§
Source§impl MemvidStoreBuilder
impl MemvidStoreBuilder
Sourcepub fn enable_lex(self) -> Self
pub fn enable_lex(self) -> Self
Enable BM25 / Tantivy lexical search on the underlying archive.
Sourcepub fn snippet_chars(self, n: usize) -> Self
pub fn snippet_chars(self, n: usize) -> Self
Number of context characters to capture around each search hit.
Defaults to 400 characters. Applies to queries issued
via VectorStoreIndex::top_n and the vec search path; callers
who need per-query control should use MemvidStore::search
directly with a hand-built SearchRequest.
Sourcepub fn acl_context(self, ctx: AclContext) -> Self
pub fn acl_context(self, ctx: AclContext) -> Self
Default AclContext attached to every search performed through
the VectorStoreIndex / vector-search interfaces. When unset,
ACL filtering is disabled.
Sourcepub fn acl_enforcement_mode(self, mode: AclEnforcementMode) -> Self
pub fn acl_enforcement_mode(self, mode: AclEnforcementMode) -> Self
ACL enforcement mode for default-attached contexts. Defaults to
AclEnforcementMode::Audit.
Sourcepub fn open(self) -> Result<MemvidStore, MemvidError>
pub fn open(self) -> Result<MemvidStore, MemvidError>
Open an existing .mv2 file. Errors if the file does not exist.
Sourcepub fn create(self) -> Result<MemvidStore, MemvidError>
pub fn create(self) -> Result<MemvidStore, MemvidError>
Create a new .mv2 file. Errors if the file already exists.
Sourcepub fn open_or_create(self) -> Result<MemvidStore, MemvidError>
pub fn open_or_create(self) -> Result<MemvidStore, MemvidError>
Open the file if it exists, otherwise create it.
Sourcepub fn open_read_only(self) -> Result<MemvidStore, MemvidError>
pub fn open_read_only(self) -> Result<MemvidStore, MemvidError>
Open the file read-only.
Trait Implementations§
Source§impl Debug for MemvidStoreBuilder
impl Debug for MemvidStoreBuilder
Source§impl Default for MemvidStoreBuilder
impl Default for MemvidStoreBuilder
Source§fn default() -> MemvidStoreBuilder
fn default() -> MemvidStoreBuilder
Auto Trait Implementations§
impl Freeze for MemvidStoreBuilder
impl RefUnwindSafe for MemvidStoreBuilder
impl Send for MemvidStoreBuilder
impl Sync for MemvidStoreBuilder
impl Unpin for MemvidStoreBuilder
impl UnsafeUnpin for MemvidStoreBuilder
impl UnwindSafe for MemvidStoreBuilder
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
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
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> 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>
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>
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