Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -61,18 +61,6 @@ def gradio_predict(input_text):
|
|
| 61 |
print(f"Detailed error: {str(e)}")
|
| 62 |
return f"Error during translation: {str(e)}"
|
| 63 |
|
| 64 |
-
# Create and launch the interface
|
| 65 |
-
demo = gr.Interface(
|
| 66 |
-
fn=gradio_predict,
|
| 67 |
-
inputs=gr.Textbox(label="English text"),
|
| 68 |
-
outputs=gr.Textbox(label="French translation"),
|
| 69 |
-
title="English to French Translator",
|
| 70 |
-
description="Enter English text to translate to French"
|
| 71 |
-
)
|
| 72 |
-
|
| 73 |
-
if __name__ == "__main__":
|
| 74 |
-
demo.launch()
|
| 75 |
-
|
| 76 |
# Gradio interface for the web app
|
| 77 |
gr.Interface(
|
| 78 |
fn=gradio_predict,
|
|
|
|
| 61 |
print(f"Detailed error: {str(e)}")
|
| 62 |
return f"Error during translation: {str(e)}"
|
| 63 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 64 |
# Gradio interface for the web app
|
| 65 |
gr.Interface(
|
| 66 |
fn=gradio_predict,
|