{"record":{"id":"c7b34b47ea63a643","repo":"run-llama/llama_index","slug":"got-a-larger-chunk-overlap-chunk-overlap-than-c7b34b","errorCode":null,"errorMessage":"Got a larger chunk overlap ({chunk_overlap}) than chunk size ({chunk_size}), should be smaller.","messagePattern":"Got a larger chunk overlap \\((.+?)\\) than chunk size \\((.+?)\\), should be smaller\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"llama-index-core/llama_index/core/node_parser/text/token.py","lineNumber":65,"sourceCode":"    _tokenizer: Callable = PrivateAttr()\n    _split_fns: List[Callable] = PrivateAttr()\n\n    def __init__(\n        self,\n        chunk_size: int = DEFAULT_CHUNK_SIZE,\n        chunk_overlap: int = DEFAULT_CHUNK_OVERLAP,\n        tokenizer: Optional[Callable] = None,\n        callback_manager: Optional[CallbackManager] = None,\n        separator: str = \" \",\n        backup_separators: Optional[List[str]] = [\"\\n\"],\n        keep_whitespaces: bool = False,\n        include_metadata: bool = True,\n        include_prev_next_rel: bool = True,\n        id_func: Optional[Callable[[int, Document], str]] = None,\n    ):\n        \"\"\"Initialize with parameters.\"\"\"\n        if chunk_overlap > chunk_size:\n            raise ValueError(\n                f\"Got a larger chunk overlap ({chunk_overlap}) than chunk size \"\n                f\"({chunk_size}), should be smaller.\"\n            )\n        callback_manager = callback_manager or CallbackManager([])\n        id_func = id_func or default_id_func\n        super().__init__(\n            chunk_size=chunk_size,\n            chunk_overlap=chunk_overlap,\n            separator=separator,\n            backup_separators=backup_separators,\n            keep_whitespaces=keep_whitespaces,\n            callback_manager=callback_manager,\n            include_metadata=include_metadata,\n            include_prev_next_rel=include_prev_next_rel,\n            id_func=id_func,\n        )\n        self._tokenizer = tokenizer or get_tokenizer()\n        all_seps = [separator] + (backup_separators or [])","sourceCodeStart":47,"sourceCodeEnd":83,"githubUrl":"https://github.com/run-llama/llama_index/blob/afd0fef371831f9bda13e5af7167cf4e981278ab/llama-index-core/llama_index/core/node_parser/text/token.py#L47-L83","documentation":"Error \"Got a larger chunk overlap ({chunk_overlap}) than chunk size ({chunk_size}), should be smaller.\" thrown in run-llama/llama_index.","triggerScenarios":"Thrown at llama-index-core/llama_index/core/node_parser/text/token.py:65 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set chunk_overlap smaller than chunk_size in TokenTextSplitter.","Increase chunk_size or decrease chunk_overlap."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"afd0fef371831f9bda13e5af7167cf4e981278ab","analyzedAt":"2026-08-15T05:42:58.429Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}