Alex3456's picture
Update app.py
a01ae42
raw
history blame contribute delete
324 Bytes
import streamlit as st
import transformers
from transformers import pipeline
classifier = pipeline("zero-shot-classification", model="facebook/bart-large-mnli")
sequence_to_classify = st.text_area("Enter the text here")
candidate_labels = ['travel', 'cooking', 'dancing']
classifier(sequence_to_classify, candidate_labels)