Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove auto install library for chromadb #1870

Merged
merged 1 commit into from
Sep 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 1 addition & 11 deletions mem0/configs/vector_stores/chroma.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,7 @@ class ChromaDbConfig(BaseModel):
try:
from chromadb.api.client import Client
except ImportError:
user_input: Any = input("The 'chromadb' library is required. Install it now? [y/N]: ")
if user_input.lower() == 'y':
try:
subprocess.check_call([sys.executable, "-m", "pip", "install", "chromadb"])
from chromadb.api.client import Client
except subprocess.CalledProcessError:
print("Failed to install 'chromadb'. Please install it manually using 'pip install chromadb'.")
sys.exit(1)
else:
print("The required 'chromadb' library is not installed.")
sys.exit(1)
raise ImportError("The 'chromadb' library is required. Please install it using 'pip install chromadb'.")
Client: ClassVar[type] = Client

collection_name: str = Field("mem0", description="Default name for the collection")
Expand Down
Loading