NLP - Sentiment Analysis Advanced
Given this code snippet for sentiment prediction, what is the output?
def predict_sentiment(text):
# returns dict with sentiment scores
return {'positive': 0.4, 'neutral': 0.5, 'negative': 0.1}
result = predict_sentiment('I like the movie but the ending was sad')
print(max(result, key=result.get))