pub struct ChunkReqPayload {Show 18 fields
pub chunk_html: Option<Option<String>>,
pub convert_html_to_text: Option<Option<bool>>,
pub fulltext_boost: Option<Option<Box<FullTextBoost>>>,
pub group_ids: Option<Option<Vec<Uuid>>>,
pub group_tracking_ids: Option<Option<Vec<String>>>,
pub image_urls: Option<Option<Vec<String>>>,
pub link: Option<Option<String>>,
pub location: Option<Option<Box<GeoInfo>>>,
pub metadata: Option<Option<Value>>,
pub num_value: Option<Option<f64>>,
pub semantic_boost: Option<Option<Box<SemanticBoost>>>,
pub semantic_content: Option<Option<String>>,
pub split_avg: Option<Option<bool>>,
pub tag_set: Option<Option<Vec<String>>>,
pub time_stamp: Option<Option<String>>,
pub tracking_id: Option<Option<String>>,
pub upsert_by_tracking_id: Option<Option<bool>>,
pub weight: Option<Option<f64>>,
}Fields§
§chunk_html: Option<Option<String>>HTML content of the chunk. This can also be plaintext. The innerText of the HTML will be used to create the embedding vector. The point of using HTML is for convienience, as some users have applications where users submit HTML content.
convert_html_to_text: Option<Option<bool>>Convert HTML to raw text before processing to avoid adding noise to the vector embeddings. By default this is true. If you are using HTML content that you want to be included in the vector embeddings, set this to false.
fulltext_boost: Option<Option<Box<FullTextBoost>>>§group_ids: Option<Option<Vec<Uuid>>>Group ids are the Trieve generated ids of the groups that the chunk should be placed into. This is useful for when you want to create a chunk and add it to a group or multiple groups in one request. Groups with these Trieve generated ids must be created first, it cannot be arbitrarily created through this route.
group_tracking_ids: Option<Option<Vec<String>>>Group tracking_ids are the user-assigned tracking_ids of the groups that the chunk should be placed into. This is useful for when you want to create a chunk and add it to a group or multiple groups in one request. If a group with the tracking_id does not exist, it will be created.
image_urls: Option<Option<Vec<String>>>Image urls are a list of urls to images that are associated with the chunk. This is useful for when you want to associate images with a chunk.
link: Option<Option<String>>Link to the chunk. This can also be any string. Frequently, this is a link to the source of the chunk. The link value will not affect the embedding creation.
location: Option<Option<Box<GeoInfo>>>§metadata: Option<Option<Value>>Metadata is a JSON object which can be used to filter chunks. This is useful for when you want to filter chunks by arbitrary metadata. Unlike with tag filtering, there is a performance hit for filtering on metadata.
num_value: Option<Option<f64>>Num value is an arbitrary numerical value that can be used to filter chunks. This is useful for when you want to filter chunks by numerical value. There is no performance hit for filtering on num_value.
semantic_boost: Option<Option<Box<SemanticBoost>>>§semantic_content: Option<Option<String>>If semantic_content is present, it will be used for creating semantic embeddings instead of the innerText chunk_html. chunk_html will still be the only thing stored and always used for fulltext functionality.
split_avg: Option<Option<bool>>Split avg is a boolean which tells the server to split the text in the chunk_html into smaller chunks and average their resulting vectors. This is useful for when you want to create a chunk from a large piece of text and want to split it into smaller chunks to create a more fuzzy average dense vector. The sparse vector will be generated normally with no averaging. By default this is false.
tag_set: Option<Option<Vec<String>>>Tag set is a list of tags. This can be used to filter chunks by tag. Unlike with metadata filtering, HNSW indices will exist for each tag such that there is not a performance hit for filtering on them.
time_stamp: Option<Option<String>>Time_stamp should be an ISO 8601 combined date and time without timezone. It is used for time window filtering and recency-biasing search results.
tracking_id: Option<Option<String>>Tracking_id is a string which can be used to identify a chunk. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk.
upsert_by_tracking_id: Option<Option<bool>>Upsert when a chunk with the same tracking_id exists. By default this is false, and the request will fail if a chunk with the same tracking_id exists. If this is true, the chunk will be updated if a chunk with the same tracking_id exists.
weight: Option<Option<f64>>Weight is a float which can be used to bias search results. This is useful for when you want to bias search results for a chunk. The magnitude only matters relative to other chunks in the chunk’s dataset dataset.
Implementations§
Source§impl ChunkReqPayload
impl ChunkReqPayload
pub fn new() -> ChunkReqPayload
Trait Implementations§
Source§impl Clone for ChunkReqPayload
impl Clone for ChunkReqPayload
Source§fn clone(&self) -> ChunkReqPayload
fn clone(&self) -> ChunkReqPayload
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ChunkReqPayload
impl Debug for ChunkReqPayload
Source§impl Default for ChunkReqPayload
impl Default for ChunkReqPayload
Source§fn default() -> ChunkReqPayload
fn default() -> ChunkReqPayload
Source§impl<'de> Deserialize<'de> for ChunkReqPayload
impl<'de> Deserialize<'de> for ChunkReqPayload
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>,
Source§impl PartialEq for ChunkReqPayload
impl PartialEq for ChunkReqPayload
Source§fn eq(&self, other: &ChunkReqPayload) -> bool
fn eq(&self, other: &ChunkReqPayload) -> bool
self and other values to be equal, and is used by ==.