Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -22,7 +22,13 @@ def load_chroma_db():
|
|
22 |
# Load from Hugging Face dataset
|
23 |
print("Using ChromaDB from Hugging Face dataset...")
|
24 |
# Download the database file from Hugging Face with authentication
|
25 |
-
db_file_path = hf_hub_download(
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
# Initialize your ChromaDB with the downloaded file
|
27 |
db = chromadb.Client(path=db_file_path)
|
28 |
return db
|
|
|
22 |
# Load from Hugging Face dataset
|
23 |
print("Using ChromaDB from Hugging Face dataset...")
|
24 |
# Download the database file from Hugging Face with authentication
|
25 |
+
db_file_path = hf_hub_download(
|
26 |
+
repo_id="Mr-Geo/chroma_db",
|
27 |
+
filename="chroma.sqlite3",
|
28 |
+
repo_type="dataset", # Specify that this is a dataset
|
29 |
+
use_auth_token=hf_token
|
30 |
+
)
|
31 |
+
print(f"Downloaded database file to: {db_file_path}")
|
32 |
# Initialize your ChromaDB with the downloaded file
|
33 |
db = chromadb.Client(path=db_file_path)
|
34 |
return db
|