MCPcopy Create free account
hub / github.com/clips/pattern / positive

Function positive

pattern/text/xx/__init__.py:198–201  ·  view source on GitHub ↗

Returns True if the given sentence has a positive sentiment.

(s, threshold=0.1, **kwargs)

Source from the content-addressed store, hash-verified

196 return sentiment(s, **kwargs)[1]
197
198def positive(s, threshold=0.1, **kwargs):
199 """ Returns True if the given sentence has a positive sentiment.
200 """
201 return polarity(s, **kwargs) >= threshold
202
203#print parse("The happy cat sat on the mat.", lemmata=True)
204#print singularize("cats")

Callers

nothing calls this directly

Calls 1

polarityFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…