pub struct SearchFilter {Show 16 fields
pub namespaces: Vec<Namespace>,
pub domains: Vec<Domain>,
pub statuses: Vec<MemoryStatus>,
pub tags: Vec<String>,
pub tags_any: Vec<String>,
pub excluded_tags: Vec<String>,
pub source_pattern: Option<String>,
pub project_id: Option<String>,
pub branch: Option<String>,
pub file_path: Option<String>,
pub created_after: Option<u64>,
pub created_before: Option<u64>,
pub min_score: Option<f32>,
pub include_tombstoned: bool,
pub entity_names: Vec<String>,
pub group_ids: Vec<String>,
}Expand description
Filter criteria for memory search.
Fields§
§namespaces: Vec<Namespace>Filter by namespaces.
domains: Vec<Domain>Filter by domains.
statuses: Vec<MemoryStatus>Filter by statuses.
Filter by tags (AND logic - must have ALL).
Filter by tags (OR logic - must have ANY).
Exclude memories with these tags.
source_pattern: Option<String>Filter by source pattern (glob-style).
project_id: Option<String>Filter by project identifier (normalized git remote URL).
branch: Option<String>Filter by branch name.
file_path: Option<String>Filter by file path (relative to repo root).
created_after: Option<u64>Minimum creation timestamp.
created_before: Option<u64>Maximum creation timestamp.
min_score: Option<f32>Minimum similarity score (0.0 to 1.0).
include_tombstoned: boolInclude tombstoned memories (default: false).
entity_names: Vec<String>Filter by entity names (memories mentioning these entities). Uses OR logic - matches memories mentioning ANY of the listed entities.
group_ids: Vec<String>Filter by group identifiers (group-scoped memories). Uses OR logic - matches memories in ANY of the listed groups.
Implementations§
Source§impl SearchFilter
impl SearchFilter
Sourcepub fn with_namespace(self, namespace: Namespace) -> Self
pub fn with_namespace(self, namespace: Namespace) -> Self
Adds a namespace filter.
Sourcepub fn with_domain(self, domain: Domain) -> Self
pub fn with_domain(self, domain: Domain) -> Self
Adds a domain filter.
Sourcepub fn with_status(self, status: MemoryStatus) -> Self
pub fn with_status(self, status: MemoryStatus) -> Self
Adds a status filter.
Sourcepub fn with_tag(self, tag: impl Into<String>) -> Self
pub fn with_tag(self, tag: impl Into<String>) -> Self
Adds a tag filter (AND logic - must have ALL).
Sourcepub fn with_tag_any(self, tag: impl Into<String>) -> Self
pub fn with_tag_any(self, tag: impl Into<String>) -> Self
Adds a tag filter (OR logic - must have ANY).
Sourcepub fn with_excluded_tag(self, tag: impl Into<String>) -> Self
pub fn with_excluded_tag(self, tag: impl Into<String>) -> Self
Adds an excluded tag filter.
Sourcepub fn with_source_pattern(self, pattern: impl Into<String>) -> Self
pub fn with_source_pattern(self, pattern: impl Into<String>) -> Self
Sets the source pattern filter (glob-style).
Sourcepub fn with_project_id(self, project_id: impl Into<String>) -> Self
pub fn with_project_id(self, project_id: impl Into<String>) -> Self
Sets the project identifier filter.
Sourcepub fn with_branch(self, branch: impl Into<String>) -> Self
pub fn with_branch(self, branch: impl Into<String>) -> Self
Sets the branch filter.
Sourcepub fn with_file_path(self, file_path: impl Into<String>) -> Self
pub fn with_file_path(self, file_path: impl Into<String>) -> Self
Sets the file path filter.
Sourcepub const fn with_min_score(self, score: f32) -> Self
pub const fn with_min_score(self, score: f32) -> Self
Sets the minimum score threshold.
Sourcepub const fn with_created_after(self, timestamp: u64) -> Self
pub const fn with_created_after(self, timestamp: u64) -> Self
Sets the created_after filter.
Sourcepub const fn with_created_before(self, timestamp: u64) -> Self
pub const fn with_created_before(self, timestamp: u64) -> Self
Sets the created_before filter.
Sourcepub const fn with_include_tombstoned(self, include: bool) -> Self
pub const fn with_include_tombstoned(self, include: bool) -> Self
Includes tombstoned memories in results.
Sourcepub fn with_entity(self, entity: impl Into<String>) -> Self
pub fn with_entity(self, entity: impl Into<String>) -> Self
Adds an entity name filter. Filters to memories mentioning this entity (OR logic with other entities).
Sourcepub fn with_entities(
self,
entities: impl IntoIterator<Item = impl Into<String>>,
) -> Self
pub fn with_entities( self, entities: impl IntoIterator<Item = impl Into<String>>, ) -> Self
Adds multiple entity name filters.
Sourcepub fn with_group_id(self, group_id: impl Into<String>) -> Self
pub fn with_group_id(self, group_id: impl Into<String>) -> Self
Adds a group identifier filter.
Filters to memories belonging to this group (OR logic with other groups).
Sourcepub fn with_group_ids(
self,
group_ids: impl IntoIterator<Item = impl Into<String>>,
) -> Self
pub fn with_group_ids( self, group_ids: impl IntoIterator<Item = impl Into<String>>, ) -> Self
Adds multiple group identifier filters.
Trait Implementations§
Source§impl Clone for SearchFilter
impl Clone for SearchFilter
Source§fn clone(&self) -> SearchFilter
fn clone(&self) -> SearchFilter
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SearchFilter
impl Debug for SearchFilter
Source§impl Default for SearchFilter
impl Default for SearchFilter
Source§fn default() -> SearchFilter
fn default() -> SearchFilter
Source§impl From<&SearchFilter> for VectorFilter
impl From<&SearchFilter> for VectorFilter
Source§fn from(filter: &SearchFilter) -> Self
fn from(filter: &SearchFilter) -> Self
Converts a SearchFilter to a VectorFilter, extracting only
the fields applicable to vector search.
Source§impl From<SearchFilter> for VectorFilter
impl From<SearchFilter> for VectorFilter
Source§fn from(filter: SearchFilter) -> Self
fn from(filter: SearchFilter) -> Self
Auto Trait Implementations§
impl Freeze for SearchFilter
impl RefUnwindSafe for SearchFilter
impl Send for SearchFilter
impl Sync for SearchFilter
impl Unpin for SearchFilter
impl UnwindSafe for SearchFilter
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].