We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent adfc03e commit da30f93Copy full SHA for da30f93
fastembed/late_interaction/colbert.py
@@ -191,6 +191,9 @@ def load_onnx_model(self) -> None:
191
self.tokenizer.encode(symbol, add_special_tokens=False).ids[0]
192
for symbol in string.punctuation
193
}
194
+ current_max_length = self.tokenizer.truncation["max_length"]
195
+ # ensure not to overflow after adding document-marker
196
+ self.tokenizer.enable_truncation(max_length=current_max_length - 1)
197
198
def embed(
199
self,
0 commit comments