fix bug with length function (#1257)

docker-utility-pexpect
Harrison Chase 1 year ago committed by GitHub
parent 10e73a3723
commit 9381005098
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -250,7 +250,7 @@ class RecursiveCharacterTextSplitter(TextSplitter):
# Now go merging things, recursively splitting longer texts.
_good_splits = []
for s in splits:
if len(s) < self._chunk_size:
if self._length_function(s) < self._chunk_size:
_good_splits.append(s)
else:
if _good_splits:

Loading…
Cancel
Save