paraphrase / app.py
makanaan's picture
Create app.py
243e29d
raw
history blame
441 Bytes
from transformers import pipeline
import gradio as gr
def parph(name= "paraphrase: This is something which I cannt understand at all."):
text2text = pipeline("text2text-generation")
#model_name = 'tuner007/pegasus_paraphrase'
text2text = pipeline('text2text-generation', model = "Vamsi/T5_Paraphrase_Paws")
text2text()
return "Hello " + name + "!!"
iface = gr.Interface(fn=parph, inputs="text", outputs="text")
iface.launch()