Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -4,11 +4,11 @@ import os
|
|
4 |
import requests
|
5 |
from huggingface_hub import AsyncInferenceClient
|
6 |
|
7 |
-
|
8 |
api_url = os.getenv('API_URL')
|
9 |
#api_url_nostream = os.getenv('API_URL_NOSTREAM')
|
10 |
#headers = {'Content-Type': 'application/json',}
|
11 |
-
headers = {"Authorization": f"Bearer {
|
12 |
client = AsyncInferenceClient(api_url)
|
13 |
|
14 |
|
|
|
4 |
import requests
|
5 |
from huggingface_hub import AsyncInferenceClient
|
6 |
|
7 |
+
HF_TOKEN = os.getenv('HF_TOKEN')
|
8 |
api_url = os.getenv('API_URL')
|
9 |
#api_url_nostream = os.getenv('API_URL_NOSTREAM')
|
10 |
#headers = {'Content-Type': 'application/json',}
|
11 |
+
headers = {"Authorization": f"Bearer {HF_TOKEN}"}
|
12 |
client = AsyncInferenceClient(api_url)
|
13 |
|
14 |
|