pub enum RankBy {
Vector {
attr: String,
query: Vec<f32>,
},
VectorKnn {
attr: String,
query: Vec<f32>,
},
Bm25 {
attr: String,
query: String,
params: Option<Bm25Params>,
},
Attribute {
attr: String,
order: Order,
},
Sum(Vec<RankBy>),
Max(Vec<RankBy>),
Product {
weight: f64,
subquery: Box<RankBy>,
},
}Variants§
Implementations§
Source§impl RankBy
impl RankBy
pub fn vector(attr: impl Into<String>, query: Vec<f32>) -> Self
pub fn vector_knn(attr: impl Into<String>, query: Vec<f32>) -> Self
pub fn bm25(attr: impl Into<String>, query: impl Into<String>) -> Self
pub fn bm25_with_params( attr: impl Into<String>, query: impl Into<String>, params: Bm25Params, ) -> Self
pub fn attribute(attr: impl Into<String>, order: Order) -> Self
pub fn asc(attr: impl Into<String>) -> Self
pub fn desc(attr: impl Into<String>) -> Self
pub fn sum(subqueries: Vec<RankBy>) -> Self
pub fn max(subqueries: Vec<RankBy>) -> Self
pub fn product(weight: f64, subquery: RankBy) -> Self
Trait Implementations§
impl StructuralPartialEq for RankBy
Auto Trait Implementations§
impl Freeze for RankBy
impl RefUnwindSafe for RankBy
impl Send for RankBy
impl Sync for RankBy
impl Unpin for RankBy
impl UnwindSafe for RankBy
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