SilviaRM's picture
Update app.py
e7ea3a0 verified
raw
history blame
566 Bytes
import gradio as gr
gr.load("models/Falconsai/text_summarization").launch()
def summarize(input):
output = get_completion(input)
return output[0]['summary_text']
gr.close_all()
demo = gr.Interface(fn=summarize,
inputs=[gr.Textbox(label="Text to summarize", lines=6)],
outputs=[gr.Textbox(label="Result", lines=3)],
title="Text summarization with Falconsai",
description="Summarize any text using the `Falconsai/text_summarization` model under the hood!"
)