Spaces:
Sleeping
Sleeping
File size: 516 Bytes
b2204f0 12854bd b2204f0 12854bd 1505e07 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
import streamlit as st
from transformers import pipeline
@st.cache_resource
def load_model():
return pipeline("zero-shot-classification", model="facebook/bart-large-mnli")
model = load_model()
st.title("Tag Detection from CNN News articles")
st.write("Enter a CNN News article URL.")
news_url = st.text_input("CNN Article URL:", placeholder="Example: https://edition.cnn.com/2024/12/19/science/stonehenge-monument-early-farmers/index.html")
categories = ["Politics", "Sports", "Weather", "Culture", "Crime"]
|