Skip to main content
Custom chunking allows you to implement your own chunking strategy by creating a class that inherits from ChunkingStrategy. This is useful when you need to split documents based on specific separators, apply custom logic, or handle domain-specific content formats.
1

Create a Python file

custom_chunking.py
2

Set up your virtual environment

3

Install dependencies

4

Run PgVector

5

Run the script

Custom Chunking Params