#[non_exhaustive]pub struct RagFileChunkingConfig {
pub chunking_config: Option<ChunkingConfig>,
/* private fields */
}Expand description
Specifies the size and overlap of chunks for RagFiles.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.chunking_config: Option<ChunkingConfig>Specifies the chunking config for RagFiles.
Implementations§
Source§impl RagFileChunkingConfig
impl RagFileChunkingConfig
pub fn new() -> Self
Sourcepub fn set_chunking_config<T: Into<Option<ChunkingConfig>>>(self, v: T) -> Self
pub fn set_chunking_config<T: Into<Option<ChunkingConfig>>>(self, v: T) -> Self
Sets the value of chunking_config.
Note that all the setters affecting chunking_config are mutually
exclusive.
Sourcepub fn fixed_length_chunking(&self) -> Option<&Box<FixedLengthChunking>>
pub fn fixed_length_chunking(&self) -> Option<&Box<FixedLengthChunking>>
The value of chunking_config
if it holds a FixedLengthChunking, None if the field is not set or
holds a different branch.
Sourcepub fn set_fixed_length_chunking<T: Into<Box<FixedLengthChunking>>>(
self,
v: T,
) -> Self
pub fn set_fixed_length_chunking<T: Into<Box<FixedLengthChunking>>>( self, v: T, ) -> Self
Sets the value of chunking_config
to hold a FixedLengthChunking.
Note that all the setters affecting chunking_config are
mutually exclusive.
Trait Implementations§
Source§impl Clone for RagFileChunkingConfig
impl Clone for RagFileChunkingConfig
Source§fn clone(&self) -> RagFileChunkingConfig
fn clone(&self) -> RagFileChunkingConfig
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RagFileChunkingConfig
impl Debug for RagFileChunkingConfig
Source§impl Default for RagFileChunkingConfig
impl Default for RagFileChunkingConfig
Source§fn default() -> RagFileChunkingConfig
fn default() -> RagFileChunkingConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for RagFileChunkingConfigwhere
RagFileChunkingConfig: Default,
impl<'de> Deserialize<'de> for RagFileChunkingConfigwhere
RagFileChunkingConfig: Default,
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 Message for RagFileChunkingConfig
impl Message for RagFileChunkingConfig
Source§impl PartialEq for RagFileChunkingConfig
impl PartialEq for RagFileChunkingConfig
Source§impl Serialize for RagFileChunkingConfig
impl Serialize for RagFileChunkingConfig
impl StructuralPartialEq for RagFileChunkingConfig
Auto Trait Implementations§
impl Freeze for RagFileChunkingConfig
impl RefUnwindSafe for RagFileChunkingConfig
impl Send for RagFileChunkingConfig
impl Sync for RagFileChunkingConfig
impl Unpin for RagFileChunkingConfig
impl UnwindSafe for RagFileChunkingConfig
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