Update app.py
Browse files
app.py
CHANGED
|
@@ -32,3 +32,12 @@ def generate_text(input_text):
|
|
| 32 |
# Remove Prompt Echo from Generated Text
|
| 33 |
cleaned_output_text = output_text.replace(input_text, "")
|
| 34 |
return cleaned_output_text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 32 |
# Remove Prompt Echo from Generated Text
|
| 33 |
cleaned_output_text = output_text.replace(input_text, "")
|
| 34 |
return cleaned_output_text
|
| 35 |
+
|
| 36 |
+
text_generation_interface = gr.Interface(
|
| 37 |
+
fn=generate_text,
|
| 38 |
+
inputs=[
|
| 39 |
+
gr.inputs.Textbox(label="Input Text"),
|
| 40 |
+
],
|
| 41 |
+
outputs=gr.inputs.Textbox(label="Generated Text"),
|
| 42 |
+
title="Falcon-7B Instruct",
|
| 43 |
+
).launch()
|