daviddwlee84 commited on
Commit
5153255
·
1 Parent(s): 9f8c7c1

Switch default model of Space as Hugging Face Discord recommend

Browse files
Files changed (1) hide show
  1. app.py +11 -8
app.py CHANGED
@@ -50,14 +50,17 @@ def get_current_time_in_timezone(timezone: str) -> str:
50
  final_answer = FinalAnswerTool()
51
 
52
  if IS_IN_HF_SPACE := os.getenv("SPACE_ID"):
53
- model_id = (
54
- # BUG: Seems we are failed to call this model => bad request
55
- "https://wxknx1kg971u7k1n.us-east-1.aws.endpoints.huggingface.cloud" # it is possible that this model may be overloaded
56
- if True
57
- # BUG: Model not loaded on the server: https://api-inference.huggingface.co/models/Qwen/Qwen2.5-Coder-32B-Instruct/v1/chat/completions. Please retry with a higher timeout (current: 120)
58
- # BUG: TooManyRequests: Please log in or use a HF access token
59
- else "Qwen/Qwen2.5-Coder-32B-Instruct" # The default value of HfApiModel
60
- )
 
 
 
61
 
62
  print("Using HfApiModel with model_id:", model_id)
63
 
 
50
  final_answer = FinalAnswerTool()
51
 
52
  if IS_IN_HF_SPACE := os.getenv("SPACE_ID"):
53
+ # model_id = (
54
+ # # BUG: Seems we are failed to call this model => bad request
55
+ # "https://wxknx1kg971u7k1n.us-east-1.aws.endpoints.huggingface.cloud" # it is possible that this model may be overloaded
56
+ # if True
57
+ # # BUG: Model not loaded on the server: https://api-inference.huggingface.co/models/Qwen/Qwen2.5-Coder-32B-Instruct/v1/chat/completions. Please retry with a higher timeout (current: 120)
58
+ # # BUG: TooManyRequests: Please log in or use a HF access token
59
+ # else "Qwen/Qwen2.5-Coder-32B-Instruct" # The default value of HfApiModel
60
+ # )
61
+
62
+ # https://discord.com/channels/879548962464493619/1336751588391391283/1338901490651103414
63
+ model_id = "deepseek-ai/DeepSeek-R1-Distill-Qwen-32B"
64
 
65
  print("Using HfApiModel with model_id:", model_id)
66