Spaces:
Running
Running
Commit ·
ff94536
1
Parent(s): e89f83f
fix: update deprecated Hugging Face api-inference URL to router.huggingface.co
Browse files- src/rag/llm_client.py +1 -1
src/rag/llm_client.py
CHANGED
|
@@ -42,7 +42,7 @@ class MultiModelClient:
|
|
| 42 |
if not self.hf_api_key:
|
| 43 |
raise ValueError("HF_API_KEY not configured")
|
| 44 |
|
| 45 |
-
url = f"https://
|
| 46 |
headers = {
|
| 47 |
"Authorization": f"Bearer {self.hf_api_key}",
|
| 48 |
"Content-Type": "application/json"
|
|
|
|
| 42 |
if not self.hf_api_key:
|
| 43 |
raise ValueError("HF_API_KEY not configured")
|
| 44 |
|
| 45 |
+
url = f"https://router.huggingface.co/hf-inference/models/{model_id}/v1/chat/completions"
|
| 46 |
headers = {
|
| 47 |
"Authorization": f"Bearer {self.hf_api_key}",
|
| 48 |
"Content-Type": "application/json"
|