Open gianvi opened 7 years ago
It is possible that tool is not getting values for interval entities (or in general composed/hierarchical ?
This is the json that Wit get me back with "domani pomeriggio":
{ “msg_id”: “0s4YSkvlzlMlH8k29”, "_text": “domani pomeriggio”, “entities”: { “datetime”: [ { “confidence”: 0.99902519427591, “values”: [ { “to”: { “value”: “2017-06-14T20:00:00+02:00”, “grain”: “hour” }, “from”: { “value”: “2017-06-14T13:00:00+02:00”, “grain”: “hour” }, “type”: “interval” } ], “to”: { “value”: “2017-06-14T20:00:00+02:00”, “grain”: “hour” }, “from”: { “value”: “2017-06-14T13:00:00+02:00”, “grain”: “hour” }, “type”: “interval” } ] } }
...and this is response in above code, using getMessage("domani pomeriggio"):
As you can see I have Datetime entity recognized with high confidence, but there is no FROM and TO sub-entities valorized
With basic datetime entity, instead, it works correctly.
Here the json from Wit:
{ “msg_id”: “066zWQAwqXDF91cjo”, "_text": “il 22 giugno alle 11”, “entities”: { “datetime”: [ { “confidence”: 0.96708812631587, “values”: [ { “value”: “2017-06-22T12:00:00+02:00”, “grain”: “hour”, “type”: “value” }, { “value”: “2018-06-22T12:00:00+02:00”, “grain”: “hour”, “type”: “value” }, { “value”: “2019-06-22T12:00:00+02:00”, “grain”: “hour”, “type”: “value” } ], “value”: “2017-06-22T12:00:00+02:00”, “grain”: “hour”, “type”: “value” } ] } }
...and this is the stack with correct value in Datetime entity:
Hmm you are right, seams like a bug here. I will look into that case
Hi, do you have an example to use your client as entity resolver?
I tryied in this way in my c# bot app:
It actually recognize that there is 1 entity (DateTime) but I cannot retrieve the Value (day after tomorrow => 13/06/2017)
(In my Wit app I have no actions already setted!) Thanks in advance