mirror of
https://github.com/hwchase17/langchain.git
synced 2025-09-12 12:59:07 +00:00
community[patch]: upgrade to recent version of mypy (#21616)
This PR upgrades community to a recent version of mypy. It inserts type: ignore on all existing failures.
This commit is contained in:
@@ -8,7 +8,7 @@ MODEL = "voyage-2"
|
||||
def test_voyagi_embedding_documents() -> None:
|
||||
"""Test voyage embeddings."""
|
||||
documents = ["foo bar"]
|
||||
embedding = VoyageEmbeddings(model=MODEL)
|
||||
embedding = VoyageEmbeddings(model=MODEL) # type: ignore[call-arg]
|
||||
output = embedding.embed_documents(documents)
|
||||
assert len(output) == 1
|
||||
assert len(output[0]) == 1024
|
||||
@@ -16,7 +16,7 @@ def test_voyagi_embedding_documents() -> None:
|
||||
|
||||
def test_voyagi_with_default_model() -> None:
|
||||
"""Test voyage embeddings."""
|
||||
embedding = VoyageEmbeddings()
|
||||
embedding = VoyageEmbeddings() # type: ignore[call-arg]
|
||||
assert embedding.model == "voyage-01"
|
||||
assert embedding.batch_size == 7
|
||||
documents = [f"foo bar {i}" for i in range(72)]
|
||||
@@ -40,6 +40,6 @@ def test_voyage_embedding_documents_multiple() -> None:
|
||||
def test_voyage_embedding_query() -> None:
|
||||
"""Test voyage embeddings."""
|
||||
document = "foo bar"
|
||||
embedding = VoyageEmbeddings(model=MODEL)
|
||||
embedding = VoyageEmbeddings(model=MODEL) # type: ignore[call-arg]
|
||||
output = embedding.embed_query(document)
|
||||
assert len(output) == 1024
|
||||
|
Reference in New Issue
Block a user