Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -50,7 +50,8 @@ class ModelManager:
|
|
50 |
def load_model(self, model_config):
|
51 |
if model_config['name'] not in self.models:
|
52 |
try:
|
53 |
-
|
|
|
54 |
except Exception as e:
|
55 |
print(f"Error loading model {model_config['name']}: {e}")
|
56 |
|
|
|
50 |
def load_model(self, model_config):
|
51 |
if model_config['name'] not in self.models:
|
52 |
try:
|
53 |
+
# Use Llama.from_pretrained from llama-cpp-python
|
54 |
+
self.models[model_config['name']] = Llama.from_pretrained(model_path=model_config['repo_id'])
|
55 |
except Exception as e:
|
56 |
print(f"Error loading model {model_config['name']}: {e}")
|
57 |
|