diff --git a/src/crewai/memory/memory.py b/src/crewai/memory/memory.py index d3eb17621..bc9f273ae 100644 --- a/src/crewai/memory/memory.py +++ b/src/crewai/memory/memory.py @@ -1,8 +1,8 @@ -from typing import Any, Dict, List, Optional, TypeVar, Generic, Callable, cast +from typing import Any, Callable, Dict, Generic, List, Optional, TypeVar, cast -from pydantic import BaseModel, Field, ConfigDict +from pydantic import BaseModel, ConfigDict, Field -from crewai.memory.storage.interface import Storage, SearchResult +from crewai.memory.storage.interface import SearchResult, Storage T = TypeVar('T', bound=Storage) diff --git a/src/crewai/memory/storage/base_rag_storage.py b/src/crewai/memory/storage/base_rag_storage.py index 3fea4c9c8..3605c04e7 100644 --- a/src/crewai/memory/storage/base_rag_storage.py +++ b/src/crewai/memory/storage/base_rag_storage.py @@ -1,7 +1,7 @@ from abc import ABC, abstractmethod from typing import Any, Dict, List, Optional -from crewai.memory.storage.interface import Storage, SearchResult +from crewai.memory.storage.interface import SearchResult, Storage class BaseRAGStorage(Storage, ABC): diff --git a/src/crewai/memory/storage/interface.py b/src/crewai/memory/storage/interface.py index 396a49325..15d92f1a1 100644 --- a/src/crewai/memory/storage/interface.py +++ b/src/crewai/memory/storage/interface.py @@ -1,5 +1,5 @@ from abc import ABC, abstractmethod -from typing import Any, Dict, List, TypeVar, Generic, TypedDict, ClassVar, Protocol, runtime_checkable +from typing import Any, ClassVar, Dict, Generic, List, Protocol, TypeVar, TypedDict, runtime_checkable from pydantic import BaseModel, ConfigDict diff --git a/tests/memory/test_custom_storage.py b/tests/memory/test_custom_storage.py index 81a513455..6ade5e42c 100644 --- a/tests/memory/test_custom_storage.py +++ b/tests/memory/test_custom_storage.py @@ -7,7 +7,7 @@ from crewai.crew import Crew from crewai.memory.entity.entity_memory import EntityMemory from crewai.memory.long_term.long_term_memory import LongTermMemory from crewai.memory.short_term.short_term_memory import ShortTermMemory -from crewai.memory.storage.interface import Storage, SearchResult +from crewai.memory.storage.interface import SearchResult, Storage from crewai.memory.user.user_memory import UserMemory