MCPcopy Index your code
hub / github.com/InfinitiBit/graphbit / TextSplitterTrait

Interface TextSplitterTrait

core/src/text_splitter.rs:165–174  ·  view source on GitHub ↗

Trait for all text splitter implementations

Source from the content-addressed store, hash-verified

163
164/// Trait for all text splitter implementations
165pub trait TextSplitterTrait: Send + Sync {
166 /// Split text into chunks
167 fn split_text(&self, text: &str) -> GraphBitResult<Vec<TextChunk>>;
168
169 /// Get the splitter configuration
170 fn config(&self) -> &TextSplitterConfig;
171
172 /// Validate configuration parameters
173 fn validate_config(&self) -> GraphBitResult<()>;
174}
175
176/// Character-based text splitter
177pub struct CharacterSplitter {

Callers

nothing calls this directly

Implementers 1

text_splitter.rscore/src/text_splitter.rs

Calls

no outgoing calls

Tested by

no test coverage detected