Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -52,7 +52,7 @@ def generate_voice(text, voice_name, api_key):
|
|
| 52 |
except Exception as e:
|
| 53 |
raise gr.Error(e)
|
| 54 |
|
| 55 |
-
def
|
| 56 |
prompt, history, passwordInput, temperature=0.2, max_new_tokens=256, top_p=0.95, repetition_penalty=1.0
|
| 57 |
):
|
| 58 |
temperature = float(temperature)
|
|
@@ -156,7 +156,7 @@ passwordInput = gr.Textbox(label="TTS Password", type="password")
|
|
| 156 |
mychatbot = gr.Chatbot(avatar_images=["./user.png", "./stella.jpg"], bubble_full_width=False, show_label=False, show_copy_button=True, likeable=True)
|
| 157 |
|
| 158 |
chat = gr.ChatInterface(
|
| 159 |
-
fn=
|
| 160 |
chatbot=mychatbot,
|
| 161 |
title="Stella ",
|
| 162 |
retry_btn=None,
|
|
|
|
| 52 |
except Exception as e:
|
| 53 |
raise gr.Error(e)
|
| 54 |
|
| 55 |
+
def generate_text(
|
| 56 |
prompt, history, passwordInput, temperature=0.2, max_new_tokens=256, top_p=0.95, repetition_penalty=1.0
|
| 57 |
):
|
| 58 |
temperature = float(temperature)
|
|
|
|
| 156 |
mychatbot = gr.Chatbot(avatar_images=["./user.png", "./stella.jpg"], bubble_full_width=False, show_label=False, show_copy_button=True, likeable=True)
|
| 157 |
|
| 158 |
chat = gr.ChatInterface(
|
| 159 |
+
fn=generate_text,
|
| 160 |
chatbot=mychatbot,
|
| 161 |
title="Stella ",
|
| 162 |
retry_btn=None,
|