Skip to content

Commit

Permalink
Fix lint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
vblagoje committed Jan 19, 2024
1 parent 084c64e commit 41bdfb8
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
from .document_embedder import CohereDocumentEmbedder
from .text_embedder import CohereTextEmbedder

__all__ = ["CohereDocumentEmbedder", "CohereTextEmbedder"]
__all__ = ["CohereDocumentEmbedder", "CohereTextEmbedder"]
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@
# SPDX-License-Identifier: Apache-2.0
import asyncio
import os
from typing import Any, Dict, List, Optional

from cohere import COHERE_API_URL, AsyncClient, Client
from haystack import Document, component, default_to_dict

from haystack_integrations.components.embedders.utils import get_async_response, get_response
from typing import Any, Dict, List, Optional


@component
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@
# SPDX-License-Identifier: Apache-2.0
import asyncio
import os
from typing import Any, Dict, List, Optional

from cohere import COHERE_API_URL, AsyncClient, Client
from haystack import component, default_to_dict

from haystack_integrations.components.embedders.utils import get_async_response, get_response
from typing import Any, Dict, List, Optional


@component
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
# SPDX-License-Identifier: Apache-2.0
from .generator import CohereGenerator

__all__ = ["CohereGenerator"]
__all__ = ["CohereGenerator"]
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
# SPDX-License-Identifier: Apache-2.0
from .chat_generator import CohereChatGenerator

__all__ = ["CohereChatGenerator"]
__all__ = ["CohereChatGenerator"]
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import logging
import os
from typing import Any, Callable, Dict, List, Optional

from haystack import component, default_from_dict, default_to_dict
from haystack.components.generators.utils import deserialize_callback_handler, serialize_callback_handler
from haystack.dataclasses import ChatMessage, ChatRole, StreamingChunk
from haystack.lazy_imports import LazyImport
from typing import Any, Callable, Dict, List, Optional

with LazyImport(message="Run 'pip install cohere'") as cohere_import:
import cohere
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,10 @@
import logging
import os
import sys
from typing import Any, Callable, Dict, List, Optional, cast

from cohere import COHERE_API_URL, Client
from cohere.responses import Generations
from haystack import DeserializationError, component, default_from_dict, default_to_dict
from typing import Any, Callable, Dict, List, Optional, cast

logger = logging.getLogger(__name__)

Expand Down

0 comments on commit 41bdfb8

Please sign in to comment.