clean up. fix type safety. address memory config docs

This commit is contained in:
Brandon Hancock
2025-02-05 15:06:34 -05:00
parent de6933b2d2
commit 5d9fcc38a3
6 changed files with 52 additions and 45 deletions

View File

@@ -11,7 +11,7 @@ class EntityMemory(Memory):
"""
def __init__(self, crew=None, embedder_config=None, storage=None, path=None):
if hasattr(crew, "memory_config") and crew.memory_config is not None:
if crew and hasattr(crew, "memory_config") and crew.memory_config is not None:
self.memory_provider = crew.memory_config.get("provider")
else:
self.memory_provider = None