Spaces:
Building
Building
Update app.py
Browse files
app.py
CHANGED
|
@@ -23,14 +23,13 @@ def generate_feedback(text):
|
|
| 23 |
feedback = response.split("Feedback:")[-1].strip() # Extract feedback portion
|
| 24 |
return feedback
|
| 25 |
|
| 26 |
-
# Set up the Gradio interface
|
| 27 |
app = gr.Interface(
|
| 28 |
fn=generate_feedback,
|
| 29 |
-
inputs=gr.
|
| 30 |
-
outputs="
|
| 31 |
-
title="
|
| 32 |
-
description="
|
| 33 |
-
"Feedback may cover tone, grammar, and word choice."
|
| 34 |
)
|
| 35 |
|
| 36 |
# Launch the app
|
|
|
|
| 23 |
feedback = response.split("Feedback:")[-1].strip() # Extract feedback portion
|
| 24 |
return feedback
|
| 25 |
|
| 26 |
+
# Set up the Gradio interface with the updated syntax
|
| 27 |
app = gr.Interface(
|
| 28 |
fn=generate_feedback,
|
| 29 |
+
inputs=gr.Textbox(lines=5, label="Your Writing", placeholder="Paste a short piece of creative writing here..."),
|
| 30 |
+
outputs=gr.Textbox(label="Feedback"),
|
| 31 |
+
title="WriteBetter",
|
| 32 |
+
description="Quick feedback on tone, grammar, and word choice."
|
|
|
|
| 33 |
)
|
| 34 |
|
| 35 |
# Launch the app
|