Examples
Text Input
File Input
Request
Parameters
The text to chunk. Can be a single string or an array of strings for batch processing. Either
text
or file
is required.File to chunk. Use multipart/form-data encoding. Either
text
or file
is required.The embedding model to use.
Chosen embedding model must return token level embeddings. Request will fail
otherwise
Maximum number of tokens per chunk.
Recursive rules recipe to follow. See all recipes on our Hugging Face
repo
Language of the document to chunk
Response
Returns
Array ofChunk
objects, each containing:
The chunk text content.
Starting character position in the original text.
Ending character position in the original text.
Number of tokens in the chunk.