Spaces:
Sleeping
Sleeping
vhr1007
commited on
Commit
·
3408e43
1
Parent(s):
8411b7d
errors
Browse files
app.py
CHANGED
@@ -47,7 +47,8 @@ if not qdrant_url or not access_token:
|
|
47 |
|
48 |
# Initialize the SentenceTransformer model with the cache directory managed by HF_HOME
|
49 |
try:
|
50 |
-
|
|
|
51 |
logging.info("Successfully loaded the SentenceTransformer model.")
|
52 |
except Exception as e:
|
53 |
logging.error(f"Failed to load the SentenceTransformer model: {e}")
|
|
|
47 |
|
48 |
# Initialize the SentenceTransformer model with the cache directory managed by HF_HOME
|
49 |
try:
|
50 |
+
cache_folder = os.path.join(hf_home_dir, "transformers_cache")
|
51 |
+
encoder = SentenceTransformer('nomic-ai/nomic-embed-text-v1.5', cache_folder=cache_folder)
|
52 |
logging.info("Successfully loaded the SentenceTransformer model.")
|
53 |
except Exception as e:
|
54 |
logging.error(f"Failed to load the SentenceTransformer model: {e}")
|