Hi! Is there a way to extract the confidence level value of the latest intent in the custom action?
Try: tracker.latest_message['intent']['confidence']
.
This is the tracker:
"tracker": {
"conversation_id": "default",
"slots": {
"slot_name": "slot_value"
},
"latest_message": {
"entities": [{"start": 0, "end": 0, "value": "string", "entity": "string", "confidence": 0}],
"intent": {"confidence": 0.6323, "name": "greet"},
"intent_ranking": [{"confidence": 0.6323, "name": "greet"}],
"text": "Hello!"
},
"latest_event_time": 1537645578.314389,
"followup_action": "string",
"paused": false,
"events": [{
"event": "slot",
"timestamp": 1559744410
}],
"latest_input_channel": "rest",
"latest_action_name": "action_listen",
"latest_action": {
"action_name": "string",
"action_text": "string"
},
"active_loop": {
"name": "restaurant_form"
}
}
2 Likes