File size: 576 Bytes
dd05042
 
4670c05
dd05042
4670c05
 
 
 
 
 
 
c51aab7
4670c05
 
 
 
 
2103051
4670c05
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import gradio as gr

from huggingface_hub import InferenceClient

"""
Chatbot based on http/s://www.gradio.app/guides/creating-a-chatbot-fast.
"""
client = InferenceClient("HuggingFaceH4/zephyr-7b-beta")
def simple_respond(message,history):
    return f"I only say Hi, regardless of what message that is passed in, like {message}"


"""
For information on how to customize the ChatInterface, per use the gradio docs: https://www.gradio.app/docs/chatinterface
"""
demo = gr.ChatInterface(
    simple_respond,
    type="messages"
)

if __name__ == "__main__":
    demo.launch()