Skip to main content

Module code

Module code 

Source
Expand description

Language-aware code splitter — uses per-language separator preferences.

This is a thin specialization of the recursive splitter that picks sensible separators per language (function/class boundaries, blank lines, then chars). It’s not a parser — for AST-aware splitting, pull in tree-sitter in a downstream crate.

Structs§

CodeSplitter
Code-aware splitter. Wraps RecursiveCharSplitter with language-tuned separators.

Enums§

CodeLanguage
Common programming languages we ship default separator orderings for.