Need your help to get slotName

#1

hi,

i don’t know how to get slotName.

for (slot_value, slot) in intentMessage.slots.items():
    print slot[0].slot_value
    print slot[0].slot_value.value
    print slot[0].slot_value.value.value
    print slot[0].raw_value
    print slot[0].entity
    print slot[0].slotName   

i can print “entity” but for “slotName” =>

May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][out] à
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][out] article
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] Traceback (most recent call last):
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] File “_ctypes/callbacks.c”, line 315, in ‘calling callback function’
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] File “/var/lib/snips/skills/tritri.meteoItent/venv/local/lib/python2.7/site-packages/hermes_python/ffi/wrappers.py”, line 61, in convert_arguments_when_invoking_function
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] return func(hermes_client, *parsed_args)
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] File “./action-tritri-meteoItent-tritri.meteoItent.py”, line 29, in subscribe_intent_callback
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] action_wrapper(hermes, intentMessage, conf)
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] File “./action-tritri-meteoItent-tritri.meteoItent.py”, line 151, in action_wrapper
May 2 18:57:40 raspberrypi snips-skill-server[2679]: INFO:snips_skill_server_lib::runner: [tritri-meteoItent-tritri.meteoItent][err] print slot[0].slotName

#2

going by the source code its called slot_name

#3

thx a lot.
i have also problems to get others properties, is there a doc which explain how to parse the itent ?

Blockquote
{
“value”: {
“kind”: “TimeInterval”,
“from”: “2019-04-30 04:00:00 +00:00”,
“to”: “2019-04-30 12:00:00 +00:00”
},

Blockquote
i want to get “kind” and “from” properties , but value.kind est KO

#4

are you using hermes-python ??

https://hermespython.readthedocs.io/en/latest/api.html?highlight=interval#hermes_python.ontology.dialogue.slot.TimeIntervalValue