chatbot / app.py
aksharasoman's picture
Update app.py
5d1de09 verified
raw
history blame contribute delete
376 Bytes
from transformers import pipeline, Conversation
import gradio as gr
chatbot = pipeline(task="conversational",model="facebook/blenderbot-400M-distill")
def launch(msg):
conversation = Conversation(msg)
conversation = chatbot(conversation)
return conversation
iface = gr.Interface(launch,
inputs= gr.Textbox(),outputs="text")
iface.launch()