Skip to main content



Sentiment tree

http://nlp.stanford.edu/sentiment/index.html

This sentiment tree program was introduced to me in my cognitive science as a relatively novel way that machines can “understand” language. It is able to predict the sentiment of a given sentence, as either very negative, negative, neutral, positive or very positive. Previous sentiment prediction systems usually worked by finding the sentiment of each word in the sentence and summing those up to find the overall sentiment. However, this can be very inaccurate when one word in the sentence changes the whole meaning of the sentence, like in the example below. Even though most of the words themselves have positive sentiments, the one word “doesn’t” changes the sentiment of the whole sentence to a negative one.

blogpost1pic

The program creates a graph of the sentence. It splits up the sentence into phrases, with each word being a node. The program decides whether these nodes are positive or negative in sentiment. The word nodes are then connected together into their respective phrases, which are also nodes. The program then decides whether the whole phrase put together is positive or negative. These phrases are then connected to other phrases, and eventually the sentiment of the whole sentence is shown in the top most node. The program “learns” through a very large database of phrases and sentences that it is taught the sentiments of. I thought this program was an interesting example of a network. The graphs in the database are similar in structure to the graphs we saw in class, but serve a different purpose. Through this database of thousands of graphs, it recognizes the connections between words and phrases and is able to figure out the sentiment of a sentence it has never seen before. This model could have implications in future artificial intelligence and natural language processing development.

Comments

Leave a Reply

Blogging Calendar

September 2015
M T W T F S S
 123456
78910111213
14151617181920
21222324252627
282930  

Archives