Expand description
Query types and search execution
Re-exports§
pub use docset::*;
Modules§
- docset
- DocSet trait and concrete implementations for document iteration.
Structs§
- Bm25
Params - BM25 parameters
- Boolean
Query - Boolean query with MUST, SHOULD, and MUST_NOT clauses
- Boost
Query - Boost query - multiplies the score of the inner query
- Count
Collector - Collector that counts all matching documents
- Dense
Vector Query - Dense vector query for similarity search
- DocAddress
- Unique document address: segment_id (hex) + local doc_id within segment
- Empty
Scorer - Empty scorer for terms that don’t exist
- Global
Stats - Global statistics aggregated across all segments (legacy)
- Global
Stats Builder - Builder for aggregating statistics from multiple segments
- Global
Stats Cache - Cached global statistics with automatic invalidation
- Heap
Entry - Entry for top-k min-heap
- Lazy
Global Stats - Lazy global statistics bound to a fixed set of segments
- Matched
Field - Matched field info with ordinals (for multi-valued fields)
- MaxScore
Executor - Unified Block-Max MaxScore executor for top-k retrieval
- Phrase
Query - Phrase query - matches documents containing terms in consecutive positions
- Range
Query - Fast-field range query.
- Reranker
Config - Configuration for L2 dense vector reranking
- Score
Collector - Efficient top-k collector using min-heap (internal, scoring-layer)
- Scored
Doc - Search result from MaxScore execution
- Scored
Position - A scored position/ordinal within a field For text fields: position is the token position For vector fields: position is the ordinal (which vector in multi-value)
- Search
Hit - Search hit with unique document address and score
- Search
Response - Search response with hits (IDs only, no documents)
- Search
Result - Search result with doc_id and score (internal use)
- Sparse
Field Stats - Statistics for a sparse vector field
- Sparse
Term Query - Query for a single sparse vector dimension.
- Sparse
Term Query Info - Info for MaxScore-optimizable sparse term queries
- Sparse
Vector Query - Sparse vector query for similarity search
- Term
Query - Term query - matches documents containing a specific term
- Term
Query Info - Info for MaxScore-optimizable term queries
- Text
Field Stats - Statistics for a full-text field
- TopK
Collector - Collector for top-k results
Enums§
- Multi
Value Combiner - Strategy for combining scores when a document has multiple values for the same field
- Query
Decomposition - Decomposition of a query for MaxScore optimization.
- Range
Bound - Inclusive range bounds in the user’s type domain.
Constants§
- BM25_B
- BM25 b parameter - controls length normalization 0 = no length normalization, 1 = full normalization
- BM25_K1
- BM25 k1 parameter - controls term frequency saturation Higher values give more weight to term frequency
Traits§
- Collector
- Trait for search result collectors
- Query
- A search query (async)
- Scorer
- Scored document stream: a DocSet that also provides scores.
Functions§
- bm25_
idf - Compute IDF (Inverse Document Frequency) using BM25 variant
- bm25_
score - Compute BM25 score for a term occurrence
- bm25_
upper_ bound - Compute BM25 upper bound score for MaxScore pruning
- bm25f_
score - Compute BM25F score with field boost
- bm25f_
upper_ bound - Compute BM25F upper bound score for MaxScore pruning with field boost
- collect_
segment - Execute a query with one or more collectors (async)
- collect_
segment_ with_ limit - Execute a query with one or more collectors and a specific limit (async)
- collect_
segment_ with_ limit_ sync - Synchronous collect with limit — uses
scorer_sync. - rerank
- Rerank L1 candidates by exact dense vector distance.
- search_
segment_ with_ count - Execute a search query on a single segment and return (results, total_seen) (async)
- search_
segment_ with_ count_ sync - Synchronous segment search — returns (results, total_seen).
- search_
segment_ with_ positions_ and_ count - Execute a search query on a single segment with positions and return (results, total_seen)
Type Aliases§
- Count
Future - Future type for count estimation
- DocPredicate
- Per-document predicate closure type (platform-aware Send+Sync bounds)
- Matched
Positions - Matched positions for a field (field_id, list of scored positions) Each position includes its individual score contribution
- Scorer
Future - Future type for scorer creation