Skip to content

Commit

Permalink
fix: address CI failures with types-pytz and CohereEmbedder updates
Browse files Browse the repository at this point in the history
Co-Authored-By: natik@airbyte.io <natik@airbyte.io>
  • Loading branch information
devin-ai-integration[bot] and natikgadzhi committed Mar 1, 2025
1 parent 42d831a commit 6350683
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
8 changes: 6 additions & 2 deletions airbyte_cdk/destinations/vector_db_based/embedder.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,9 +145,13 @@ class CohereEmbedder(Embedder):
def __init__(self, config: CohereEmbeddingConfigModel):
super().__init__()
# Client is set internally
from pydantic import SecretStr

self.embeddings = CohereEmbeddings(
cohere_api_key=config.cohere_key, model="embed-english-light-v2.0"
) # type: ignore
api_key=SecretStr(config.cohere_key),
model="embed-english-light-v2.0",
client_kwargs={"user_agent": "langchain"}
)

def check(self) -> Optional[str]:
try:
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ types-requests = "^2.32.0.20241016"
types-python-dateutil = "^2.9.0.20241003"
types-pyyaml = "^6.0.12.20240917"
types-cachetools = "^5.5.0.20240820"
types-pytz = "^2024.1.0.20240417"

[tool.poetry.extras]
file-based = ["avro", "fastavro", "pyarrow", "unstructured", "pdf2image", "pdfminer.six", "unstructured.pytesseract", "pytesseract", "markdown", "python-calamine", "python-snappy", "pi_heif"]
Expand Down

0 comments on commit 6350683

Please sign in to comment.