Ask a question to get started
Enter to sendā¢Shift+Enter new line
Generate batches of documents based on page_content size. Args: docs: List of documents to be batched. max_batch_size: Maximum size of each batch in bytes. Defaults to 100*1024(100KB) Returns: List[List[Document]]: List of batches of documents
generate_size_based_batches( docs: List[Document], max_batch_size: int = 100 * 1024 ) -> List[List[Document]]