Skip to content

Instantly share code, notes, and snippets.

@JessicaWachtel
Created November 28, 2025 15:42
Show Gist options
  • Select an option

  • Save JessicaWachtel/3c0e2fd786114409a8217bee7fea5050 to your computer and use it in GitHub Desktop.

Select an option

Save JessicaWachtel/3c0e2fd786114409a8217bee7fea5050 to your computer and use it in GitHub Desktop.
classifier = pipeline("sentiment-analysis")
text = "I love sunny days."
result = classifier(text)
text2 = "I don't like the rain."
result2 = classifier(text2)
print("\n=== Sentiment Analysis ===")
print(result)
print(result2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment