broadfield-dev's picture
Initial Space setup of broadfield-dev/my-translator-app via Builder
79a132f verified
raw
history blame contribute delete
426 Bytes
`# This is the main entry point for the Gradio app`
`import gradio as gr`
`from translate import translate_text`
`def main():`
` with gr.Blocks() as demo:`
` with demo.Form():`
` text = gr.Textbox(label="Enter English text")`
` submit = gr.Button("Translate")`
` output = gr.Textbox(label="Translated French text")`
` demo.launch()``
`if __name__ == "__main__":`
` main()`