pub struct SearchChunksReqPayload {Show 14 fields
pub content_only: Option<Option<bool>>,
pub filters: Option<Option<Box<ChunkFilter>>>,
pub get_total_pages: Option<Option<bool>>,
pub highlight_options: Option<Option<Box<HighlightOptions>>>,
pub page: Option<Option<i64>>,
pub page_size: Option<Option<i64>>,
pub query: Box<QueryTypes>,
pub remove_stop_words: Option<Option<bool>>,
pub score_threshold: Option<Option<f32>>,
pub search_type: SearchMethod,
pub slim_chunks: Option<Option<bool>>,
pub sort_options: Option<Option<Box<SortOptions>>>,
pub use_quote_negated_terms: Option<Option<bool>>,
pub user_id: Option<Option<String>>,
}Fields§
§content_only: Option<Option<bool>>Set content_only to true to only returning the chunk_html of the chunks. This is useful for when you want to reduce amount of data over the wire for latency improvement (typically 10-50ms). Default is false.
filters: Option<Option<Box<ChunkFilter>>>§get_total_pages: Option<Option<bool>>Get total page count for the query accounting for the applied filters. Defaults to false, but can be set to true when the latency penalty is acceptable (typically 50-200ms).
highlight_options: Option<Option<Box<HighlightOptions>>>§page: Option<Option<i64>>Page of chunks to fetch. Page is 1-indexed.
page_size: Option<Option<i64>>Page size is the number of chunks to fetch. This can be used to fetch more than 10 chunks at a time.
query: Box<QueryTypes>§remove_stop_words: Option<Option<bool>>If true, stop words (specified in server/src/stop-words.txt in the git repo) will be removed. Queries that are entirely stop words will be preserved.
score_threshold: Option<Option<f32>>Set score_threshold to a float to filter out chunks with a score below the threshold for cosine distance metric For Manhattan Distance, Euclidean Distance, and Dot Product, it will filter out scores above the threshold distance This threshold applies before weight and bias modifications. If not specified, this defaults to no threshold A threshold of 0 will default to no threashold
search_type: SearchMethod§slim_chunks: Option<Option<bool>>Set slim_chunks to true to avoid returning the content and chunk_html of the chunks. This is useful for when you want to reduce amount of data over the wire for latency improvement (typically 10-50ms). Default is false.
sort_options: Option<Option<Box<SortOptions>>>§use_quote_negated_terms: Option<Option<bool>>If true, quoted and - prefixed words will be parsed from the queries and used as required and negated words respectively. Default is false.
user_id: Option<Option<String>>User ID is the id of the user who is making the request. This is used to track user interactions with the search results.
Implementations§
Source§impl SearchChunksReqPayload
impl SearchChunksReqPayload
pub fn new( query: QueryTypes, search_type: SearchMethod, ) -> SearchChunksReqPayload
Trait Implementations§
Source§impl Clone for SearchChunksReqPayload
impl Clone for SearchChunksReqPayload
Source§fn clone(&self) -> SearchChunksReqPayload
fn clone(&self) -> SearchChunksReqPayload
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more