Method: Langchain::Chunker::RecursiveText#initialize
- Defined in:
- lib/langchain/chunker/recursive_text.rb
#initialize(text, chunk_size: 1000, chunk_overlap: 200, separators: ["\n\n"]) ⇒ RecursiveText
Returns a new instance of RecursiveText.
18 19 20 21 22 23 |
# File 'lib/langchain/chunker/recursive_text.rb', line 18 def initialize(text, chunk_size: 1000, chunk_overlap: 200, separators: ["\n\n"]) @text = text @chunk_size = chunk_size @chunk_overlap = chunk_overlap @separators = separators end |