Skip to content

Commit 38617cb

Browse files
committed
refactor: remove skip of last
1 parent b96be9e commit 38617cb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

chunked_pooling/chunking.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ def chunk_by_tokens(
170170

171171
chunk_spans = []
172172
for i in range(0, len(token_offsets), chunk_size):
173-
chunk_end = min(i + chunk_size, len(token_offsets) - 1)
173+
chunk_end = min(i + chunk_size, len(token_offsets))
174174
if chunk_end - i > 0:
175175
chunk_spans.append((i, chunk_end))
176176

0 commit comments

Comments
 (0)