Update app.py
Browse filestry to add api token to access ugh
app.py
CHANGED
@@ -5,6 +5,8 @@ import pytz
|
|
5 |
import yaml
|
6 |
from tools.final_answer import FinalAnswerTool
|
7 |
import os
|
|
|
|
|
8 |
|
9 |
from Gradio_UI import GradioUI
|
10 |
|
@@ -89,6 +91,7 @@ model = HfApiModel(
|
|
89 |
max_tokens=2096,
|
90 |
temperature=0.5,
|
91 |
model_id='microsoft/Phi-4-mini-instruct',
|
|
|
92 |
#model_id='Qwen/Qwen2.5-Coder-32B-Instruct',# it is possible that this model may be overloaded
|
93 |
custom_role_conversions=None
|
94 |
)
|
|
|
5 |
import yaml
|
6 |
from tools.final_answer import FinalAnswerTool
|
7 |
import os
|
8 |
+
# Access the token from environment variables
|
9 |
+
#hf_token = os.environ.get("HF_TOKEN")
|
10 |
|
11 |
from Gradio_UI import GradioUI
|
12 |
|
|
|
91 |
max_tokens=2096,
|
92 |
temperature=0.5,
|
93 |
model_id='microsoft/Phi-4-mini-instruct',
|
94 |
+
api_token=os.environ.get("HF_TOKEN"),
|
95 |
#model_id='Qwen/Qwen2.5-Coder-32B-Instruct',# it is possible that this model may be overloaded
|
96 |
custom_role_conversions=None
|
97 |
)
|