pub struct MultiQuery {
pub queries: Vec<SubQuery>,
pub topk_value: i32,
pub filter: Option<String>,
pub include_vector_value: bool,
pub output_fields: Option<Vec<String>>,
pub rerank: RerankMethod,
pub normalization: Option<String>,
}Expand description
A collection of sub-queries fused into one ranked result.
Fields§
§queries: Vec<SubQuery>§topk_value: i32§filter: Option<String>§include_vector_value: bool§output_fields: Option<Vec<String>>§rerank: RerankMethod§normalization: Option<String>Implementations§
Source§impl MultiQuery
impl MultiQuery
pub fn new() -> Result<Self>
pub fn add_sub_query(&mut self, sub: &SubQuery) -> Result<()>
pub fn sub_query_count(&self) -> usize
pub fn set_topk(&mut self, topk: i32) -> Result<()>
pub fn topk(&self) -> i32
pub fn set_filter(&mut self, filter: &str) -> Result<()>
pub fn set_include_vector(&mut self, include: bool) -> Result<()>
pub fn include_vector(&self) -> bool
pub fn set_output_fields(&mut self, fields: &[&str]) -> Result<()>
pub fn set_rerank_rrf(&mut self, rank_constant: i32) -> Result<()>
pub fn set_rerank_weighted(&mut self, weights: &[f64]) -> Result<()>
pub fn set_normalization(&mut self, method: &str) -> Result<()>
Trait Implementations§
Source§impl Clone for MultiQuery
impl Clone for MultiQuery
Source§impl Debug for MultiQuery
impl Debug for MultiQuery
Source§impl<'de> Deserialize<'de> for MultiQuery
impl<'de> Deserialize<'de> for MultiQuery
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for MultiQuery
impl PartialEq for MultiQuery
Source§impl Serialize for MultiQuery
impl Serialize for MultiQuery
impl StructuralPartialEq for MultiQuery
Auto Trait Implementations§
impl Freeze for MultiQuery
impl RefUnwindSafe for MultiQuery
impl Send for MultiQuery
impl Sync for MultiQuery
impl Unpin for MultiQuery
impl UnsafeUnpin for MultiQuery
impl UnwindSafe for MultiQuery
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> ⓘ
Converts
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> ⓘ
Converts
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