foleymon commited on
Commit
041e079
·
verified ·
1 Parent(s): c527759

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -0
app.py CHANGED
@@ -3,6 +3,7 @@ import datetime
3
  import requests
4
  import pytz
5
  import yaml
 
6
  from tools.final_answer import FinalAnswerTool
7
  from Gradio_UI import GradioUI
8
 
@@ -34,6 +35,11 @@ def get_current_time_in_timezone(timezone: str) -> str:
34
 
35
  final_answer = FinalAnswerTool()
36
 
 
 
 
 
 
37
  # If the agent does not answer, the model is overloaded, please use another model or the following Hugging Face Endpoint that also contains qwen2.5 coder:
38
  # model_id='https://pflgm2locj2t89co.us-east-1.aws.endpoints.huggingface.cloud'
39
 
 
3
  import requests
4
  import pytz
5
  import yaml
6
+ import spaces
7
  from tools.final_answer import FinalAnswerTool
8
  from Gradio_UI import GradioUI
9
 
 
35
 
36
  final_answer = FinalAnswerTool()
37
 
38
+ @spaces.GPU(duration=120)
39
+ def _zero_gpu_check() -> str:
40
+ """Placeholder GPU function so the ZeroGPU runtime detects a GPU function."""
41
+ return "ok"
42
+
43
  # If the agent does not answer, the model is overloaded, please use another model or the following Hugging Face Endpoint that also contains qwen2.5 coder:
44
  # model_id='https://pflgm2locj2t89co.us-east-1.aws.endpoints.huggingface.cloud'
45