mokadi.mokadi_action_emotion
¶module botadi.mokadi.mokadi_action_emotion
Defines an action for Mokadi.
class |
truncated documentation |
---|---|
Action. Emotion. Takes a picture and analyses it. |
method |
truncated documentation |
---|---|
Constructor. |
|
Returns the emotion as text. |
|
Tells if the class can process the message. |
|
return a picture name |
|
Processes the interpreted message. |
Defines an action for Mokadi.
Bases: botadi.mokadi.mokadi_action.MokadiAction
Action. Emotion. Takes a picture and analyses it.
Constructor.
subkey – subscription key
folder – where to save the picture (must exist)
fLOG – logging function
Constructor.
subkey – subscription key
folder – where to save the picture (must exist)
fLOG – logging function
Returns the emotion as text.
scores – dictionary
string
Example for scores:
'scores': {'anger': 0.000243422386, 'contempt': 0.00207486819,
'disgust': 2.390567e-05, 'fear': 2.512976e-07,
'happiness': 3.5321933e-05, 'neutral': 0.9925101,
'sadness': 0.00510106329, 'surprise': 1.10992869e-05}}]
Tells if the class can process the message.
interpreted – interpreted message
message – message
true if the class can process the message
return a picture name
Processes the interpreted message.
interpretation – interpretation
message – original message
iterator on Info