Spaces:
Runtime error
Runtime error
Update src/get_medical_system.py
Browse files
src/get_medical_system.py
CHANGED
|
@@ -22,6 +22,11 @@ def get_vector_store():
|
|
| 22 |
|
| 23 |
try:
|
| 24 |
# Load pre-computed data
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25 |
print("📥 Loading pre-computed embeddings...")
|
| 26 |
embeddings_array = np.load('src/medical_embeddings.npy')
|
| 27 |
|
|
|
|
| 22 |
|
| 23 |
try:
|
| 24 |
# Load pre-computed data
|
| 25 |
+
|
| 26 |
+
if not os.path.exists('src/medical_embeddings.npy'):
|
| 27 |
+
raise FileNotFoundError("medical_embeddings.npy not found")
|
| 28 |
+
if not os.path.exists('src/medical_texts.pkl'):
|
| 29 |
+
raise FileNotFoundError("medical_texts.pkl not found")
|
| 30 |
print("📥 Loading pre-computed embeddings...")
|
| 31 |
embeddings_array = np.load('src/medical_embeddings.npy')
|
| 32 |
|