Spaces:
Runtime error
Runtime error
from transformers import AutoTokenizer, AutoModelForSequenceClassification | |
from transformers import pipeline | |
tokenizer = AutoTokenizer.from_pretrained("Alanhau/test") | |
model = AutoModelForSequenceClassification.from_pretrained("Alanhau/test") | |
nlp = pipeline("sentiment-analysis", model=model, tokenizer=tokenizer) | |
sentences = ["hate you!"] | |
results = nlp(sentences) | |
print(results) |