Spaces:
Runtime error
Runtime error
import streamlit as st | |
from transformers import pipeline | |
classifier = pipeline("zero-shot-classification", model="MoritzLaurer/DeBERTa-v3-base-mnli-fever-anli") | |
sequence_to_classify = "Angela Merkel is a politician in Germany and leader of the CDU" | |
candidate_labels = ["politics", "economy", "entertainment", "environment"] | |
output = classifier(sequence_to_classify, candidate_labels, multi_label=False) | |
st.write(output) | |