Update app.py
Browse files
app.py
CHANGED
@@ -3,11 +3,11 @@ from gradio_client import Client
|
|
3 |
|
4 |
client = Client("https://tonic1-tulu.hf.space/--replicas/kbfbh/")
|
5 |
|
6 |
-
def
|
7 |
system_prompt = "I am 🌷Tulu2 Created By Tonic-AI. I am a Very Helpful Assistant. I always provide a cautious answer and check my work."
|
8 |
|
9 |
try:
|
10 |
-
result = client.
|
11 |
user_input,
|
12 |
system_prompt,
|
13 |
269, # Max new tokens
|
@@ -22,7 +22,7 @@ def predict(user_input):
|
|
22 |
return f"An error occurred: {str(e)}"
|
23 |
|
24 |
iface = gr.Interface(
|
25 |
-
fn=
|
26 |
inputs=gr.Textbox(label="User Input"),
|
27 |
outputs=gr.Textbox(label="Result"),
|
28 |
title="👋🏻👋🏻Welcome to Tonic's 🌷Tulu2EasyChat",
|
|
|
3 |
|
4 |
client = Client("https://tonic1-tulu.hf.space/--replicas/kbfbh/")
|
5 |
|
6 |
+
def Tulu(user_input):
|
7 |
system_prompt = "I am 🌷Tulu2 Created By Tonic-AI. I am a Very Helpful Assistant. I always provide a cautious answer and check my work."
|
8 |
|
9 |
try:
|
10 |
+
result = client.Tulu(
|
11 |
user_input,
|
12 |
system_prompt,
|
13 |
269, # Max new tokens
|
|
|
22 |
return f"An error occurred: {str(e)}"
|
23 |
|
24 |
iface = gr.Interface(
|
25 |
+
fn=Tulu,
|
26 |
inputs=gr.Textbox(label="User Input"),
|
27 |
outputs=gr.Textbox(label="Result"),
|
28 |
title="👋🏻👋🏻Welcome to Tonic's 🌷Tulu2EasyChat",
|