pub struct Bm25Params { /* private fields */ }Expand description
Validated BM25 hyperparameters for document-side local encoding.
Only documents are affected: query text always embeds with unit term
weights, and IDF is applied by the backend from the sparse vector’s
modifier: idf. This is a client-side, write-path-only knob — it is not a
collection/wire setting, and it does not change server-side qdrant/bm25
inference. Vectors written before a change stay as written; re-ingest to
apply new parameters.
Construct via Bm25Params::new (or Bm25Params::resolve for optional
overrides); invalid values fail closed with QQL-VALIDATION-CONFIG.
Implementations§
Source§impl Bm25Params
impl Bm25Params
Sourcepub fn new(k1: f64, b: f64, avg_len: f64) -> Result<Self, QqlError>
pub fn new(k1: f64, b: f64, avg_len: f64) -> Result<Self, QqlError>
Validate and build explicit BM25 parameters.
k1 must be finite and > 0, b finite and within [0, 1], and
avg_len finite and > 0. NaN and ±Inf are rejected for all three.
Trait Implementations§
Source§impl Clone for Bm25Params
impl Clone for Bm25Params
Source§fn clone(&self) -> Bm25Params
fn clone(&self) -> Bm25Params
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for Bm25Params
Source§impl Debug for Bm25Params
impl Debug for Bm25Params
Source§impl Default for Bm25Params
impl Default for Bm25Params
Source§impl PartialEq for Bm25Params
impl PartialEq for Bm25Params
impl StructuralPartialEq for Bm25Params
Auto Trait Implementations§
impl Freeze for Bm25Params
impl RefUnwindSafe for Bm25Params
impl Send for Bm25Params
impl Sync for Bm25Params
impl Unpin for Bm25Params
impl UnsafeUnpin for Bm25Params
impl UnwindSafe for Bm25Params
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