mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-05-05 17:22:36 +00:00
fix: surfacing properly supported types by Mem0Storage
This commit is contained in:
committed by
Lucas Gomide
parent
9b51e1174c
commit
13115c68bd
@@ -13,9 +13,12 @@ class Mem0Storage(Storage):
|
||||
|
||||
def __init__(self, type, crew=None):
|
||||
super().__init__()
|
||||
|
||||
if type not in ["user", "short_term", "long_term", "entities"]:
|
||||
raise ValueError("Invalid type for Mem0Storage. Must be 'user' or 'agent'.")
|
||||
supported_types = ["user", "short_term", "long_term", "entities"]
|
||||
if type not in supported_types:
|
||||
raise ValueError(
|
||||
"Invalid type for Mem0Storage. Must be one of: "
|
||||
+ ", ".join(supported_types)
|
||||
)
|
||||
|
||||
self.memory_type = type
|
||||
self.crew = crew
|
||||
|
||||
Reference in New Issue
Block a user