fix(py): py with build-in package typing not typing_extensions (#99)

This commit is contained in:
Cuiys 2026-02-12 23:38:18 +08:00 committed by GitHub
parent 1fa15ce96b
commit 1d5aeeed1d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 4 deletions

View File

@ -13,10 +13,9 @@
# limitations under the License.
from __future__ import annotations
from typing import Optional, Union
from typing import Optional, TypeVar, Union
import numpy as np
from typing_extensions import TypeVar
# VectorType: DenseVectorType | SparseVectorType
DenseVectorType = Union[list[float], list[int], np.ndarray]

View File

@ -14,8 +14,7 @@
from __future__ import annotations
from abc import abstractmethod
from typing_extensions import Protocol, runtime_checkable
from typing import Protocol, runtime_checkable
from ..common.constants import MD, DenseVectorType, SparseVectorType