sentiment_analysis.py
# Simple AI Demo: Sentiment Analysis

from textblob import TextBlob

text = "Artificial Intelligence is making our lives easier."
analysis = TextBlob(text)

print("Text:", text)
print("Sentiment Score:", analysis.sentiment.polarity)

if analysis.sentiment.polarity > 0:
    print("Prediction: Positive 😊")
elif analysis.sentiment.polarity < 0:
    print("Prediction: Negative 😞")
else:
    print("Prediction: Neutral 😐")

pyguru.ai