release(mistralai): 1.0.0a1 (#33232)

This commit is contained in:
Mason Daugherty
2025-10-02 19:04:03 -04:00
committed by GitHub
parent e85b03d5e4
commit 79a12c8f27
4 changed files with 34 additions and 37 deletions

View File

@@ -7,11 +7,11 @@ import os
import re
import ssl
import uuid
from collections.abc import Callable # noqa: TC003
from operator import itemgetter
from typing import (
TYPE_CHECKING,
Any,
Callable,
Literal,
Optional,
Union,

View File

@@ -202,7 +202,7 @@ class MistralAIEmbeddings(BaseModel, Embeddings):
len(encoded) for encoded in self.tokenizer.encode_batch(texts)
]
for text, text_tokens in zip(texts, text_token_lengths):
for text, text_tokens in zip(texts, text_token_lengths, strict=False):
if batch_tokens + text_tokens > MAX_TOKENS:
if len(batch) > 0:
# edge case where first batch exceeds max tokens