Spaces:
Sleeping
Sleeping
Commit ·
bdebbca
1
Parent(s): 4701079
trying
Browse files
app.py
CHANGED
|
@@ -19,15 +19,12 @@ def generate_text(input_text):
|
|
| 19 |
def analyze_sentiment(input_text):
|
| 20 |
return input_text
|
| 21 |
|
| 22 |
-
def echo_text(input_text):
|
| 23 |
-
return input_text
|
| 24 |
|
| 25 |
# Define the Gradio interface
|
| 26 |
interface1 = gr.Interface(fn=generate_text, inputs="text", outputs="text")
|
| 27 |
interface2 = gr.Interface(fn=analyze_sentiment, inputs="text", outputs="text")
|
| 28 |
-
interface3 = gr.Interface(fn=echo_text, inputs="text", outputs="text")
|
| 29 |
|
| 30 |
-
tabbed_interface = gr.TabbedInterface([interface1, interface2
|
| 31 |
|
| 32 |
if __name__ == "__main__":
|
| 33 |
tabbed_interface.launch()
|
|
|
|
| 19 |
def analyze_sentiment(input_text):
|
| 20 |
return input_text
|
| 21 |
|
|
|
|
|
|
|
| 22 |
|
| 23 |
# Define the Gradio interface
|
| 24 |
interface1 = gr.Interface(fn=generate_text, inputs="text", outputs="text")
|
| 25 |
interface2 = gr.Interface(fn=analyze_sentiment, inputs="text", outputs="text")
|
|
|
|
| 26 |
|
| 27 |
+
tabbed_interface = gr.TabbedInterface([interface1, interface2], ["Text Generation", "Sentiment Analysis", "Echo Text"])
|
| 28 |
|
| 29 |
if __name__ == "__main__":
|
| 30 |
tabbed_interface.launch()
|