OpenAI::StaticChunkingStrategy
Inherits JSON::Serializable < Reference < Object
Constructors
new(pull : JSON::PullParser)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceInstance methods
chunk_overlap_tokens
The number of tokens that overlap between chunks. The default value is 400.
Note that the overlap must not exceed half of max_chunk_size_tokens.
chunk_overlap_tokens=(chunk_overlap_tokens : Int64)
The number of tokens that overlap between chunks. The default value is 400.
Note that the overlap must not exceed half of max_chunk_size_tokens.
max_chunk_size_tokens
The maximum number of tokens in each chunk. The default value is 800. The minimum value is 100 and the maximum value is 4096.
max_chunk_size_tokens=(max_chunk_size_tokens : Int64)
The maximum number of tokens in each chunk. The default value is 800. The minimum value is 100 and the maximum value is 4096.
validate!
Source