TejAndrewsACC commited on
Commit
0c9f765
·
verified ·
1 Parent(s): 917a0f8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -1
app.py CHANGED
@@ -1,5 +1,6 @@
1
  from huggingface_hub import InferenceClient
2
  import os
 
3
 
4
  hf_token = os.getenv("HF_TOKEN").strip()
5
 
@@ -19,4 +20,14 @@ stream = client.chat.completions.create(
19
  )
20
 
21
  for chunk in stream:
22
- print(chunk.choices[0].delta.content)
 
 
 
 
 
 
 
 
 
 
 
1
  from huggingface_hub import InferenceClient
2
  import os
3
+ import gradio as gr
4
 
5
  hf_token = os.getenv("HF_TOKEN").strip()
6
 
 
20
  )
21
 
22
  for chunk in stream:
23
+ print(chunk.choices[0].delta.content)
24
+
25
+ demo = gr.ChatInterface(
26
+ fn=chat_with_model,
27
+ title="ACC-o3",
28
+ description="ACC=o3 is a powerful model created by the ACC.",
29
+ examples=["How many 'r's are in strawberry?", "Tell me about the ACC.", "Who are you?"]
30
+ )
31
+
32
+ if __name__ == "__main__":
33
+ demo.launch()