Skip to content

Commit

Permalink
More linting fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
vblagoje committed Jan 19, 2024
1 parent 41bdfb8 commit e935a1c
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@
# 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,10 +3,11 @@
# 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
@@ -1,10 +1,11 @@
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,10 +4,11 @@
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
1 change: 0 additions & 1 deletion integrations/cohere/tests/test_cohere_chat_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import pytest
from haystack.components.generators.utils import default_streaming_callback
from haystack.dataclasses import ChatMessage, ChatRole, StreamingChunk

from haystack_integrations.components.generators.chat import CohereChatGenerator

pytestmark = pytest.mark.chat_generators
Expand Down
1 change: 0 additions & 1 deletion integrations/cohere/tests/test_cohere_generators.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

import pytest
from cohere import COHERE_API_URL

from haystack_integrations.components.generators import CohereGenerator

pytestmark = pytest.mark.generators
Expand Down
1 change: 0 additions & 1 deletion integrations/cohere/tests/test_document_embedder.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import pytest
from cohere import COHERE_API_URL
from haystack import Document

from haystack_integrations.components.embedders import CohereDocumentEmbedder

pytestmark = pytest.mark.embedders
Expand Down
1 change: 0 additions & 1 deletion integrations/cohere/tests/test_text_embedder.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

import pytest
from cohere import COHERE_API_URL

from haystack_integrations.components.embedders import CohereTextEmbedder

pytestmark = pytest.mark.embedders
Expand Down

0 comments on commit e935a1c

Please sign in to comment.