Algorithm to determine how positive or negative a statement/text is

前端 未结 14 1522
北荒
北荒 2020-12-07 07:21

I need an algorithm to determine if a sentence, paragraph or article is negative or positive in tone... or better yet, how negative or positive.

For instance:

<
14条回答
  •  没有蜡笔的小新
    2020-12-07 07:57

    You can do like this:

        Jason is the worst SO user I have ever witnessed (-10)
    

    worst (-), the rest is (+). so, that would be (-) + (+) = (-)

        Jason is an SO user (0)
    

    ( ) + ( ) = ( )

        Jason is the best SO user I have ever seen (+10)
    

    best (+) , the rest is ( ). so, that would be (+) + ( ) = (+)

        Jason is the best at sucking with SO (-10)
    

    best (+), sucking (-). so, (+) + (-) = (-)

        While, okay at SO, Jason is the worst at doing bad (+10)
    

    worst (-), doing bad (-). so, (-) + (-) = (+)

提交回复
热议问题