/** * Methods for splitting text into chunks for embedding generation. */ export type ChunkingMethod = "PlainTextSplit" | "PlainTextSplitLines" | "PlainTextSplitParagraphs" | "MarkDownSplitLines" | "MarkDownSplitParagraphs" | "HtmlStrip"; /** * Configuration for chunking text into smaller pieces for embedding generation. */ export interface ChunkingOptions { /** * The method to use for splitting text into chunks. */ chunkingMethod: ChunkingMethod; /** * Maximum number of tokens per chunk. * @default 512 */ maxTokensPerChunk: number; /** * Number of tokens to overlap between consecutive chunks. * Only supported for MarkDownSplitParagraphs and PlainTextSplitParagraphs. * @default 0 */ overlapTokens: number; } /** * Chunking methods that support overlap tokens. */ export declare const METHODS_SUPPORTING_OVERLAP_TOKENS: ChunkingMethod[]; /** * Validates chunking options and returns an array of error messages. * @param options The chunking options to validate * @param source The source/context of the validation (e.g., field name) for better error messages * @returns Array of validation error messages, empty if valid */ export declare function validateChunkingOptions(source: string, options: ChunkingOptions): string[]; /** * Compares two ChunkingOptions for equality. * @param left First chunking options to compare * @param right Second chunking options to compare * @returns true if both are equal or both are null/undefined, false otherwise */ export declare function areChunkingOptionsEqual(left: ChunkingOptions, right: ChunkingOptions): boolean; //# sourceMappingURL=ChunkingOptions.d.ts.map