jam134 commited on
Commit
897eb38
·
verified ·
1 Parent(s): 67a4be3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -1,6 +1,6 @@
1
  import gradio as gr
2
  from huggingface_hub import InferenceClient
3
-
4
  """
5
  For more information on `huggingface_hub` Inference API support, please check the docs: https://huggingface.co/docs/huggingface_hub/v0.22.2/en/guides/inference
6
  """
@@ -57,7 +57,10 @@ demo = gr.ChatInterface(
57
  ),
58
  ],
59
  )
60
-
 
 
61
 
62
  if __name__ == "__main__":
63
- demo.launch()
 
 
1
  import gradio as gr
2
  from huggingface_hub import InferenceClient
3
+ from keep_alive import keep_alive
4
  """
5
  For more information on `huggingface_hub` Inference API support, please check the docs: https://huggingface.co/docs/huggingface_hub/v0.22.2/en/guides/inference
6
  """
 
57
  ),
58
  ],
59
  )
60
+ def main():
61
+ urls = ['網址1', '網址2', '網址3'] # 替換為你的多個網址
62
+ keep_alive(urls)
63
 
64
  if __name__ == "__main__":
65
+ demo.launch()
66
+ main()