Hi all, so I am using an external python program for my intent handling purposes and as I was testing it, I may have found a potential bug (I hope it’s just an error on my side, since this is easier to fix, so please let me know if this is the case).
From my script, I am printing this JSON to stdout:
{
"intent": {"name": "TimerSet"},
"entities": [
{"entity": "hour", "value": "2"},
{"entity": "minute", "value": "30"}
],
"text": "set a timer for 2 hours and 30 minutes"
}
When I “Recognize” (e.g., type in the sentence and hit the Recognize button) this on the Rhasspy localhost, I get this:
{
"entities": [
{
"end": 1,
"entity": "hour",
"raw_end": 1,
"raw_start": 0,
"raw_value": "2",
"start": 0,
"value": [
"value"
],
"value_details": {
"value": [
"value"
]
}
},
{
"end": 1,
"entity": "minute",
"raw_end": 1,
"raw_start": 0,
"raw_value": "30",
"start": 0,
"value": [
"value"
],
"value_details": {
"value": [
"value"
]
}
}
],
"intent": {
"confidence": 1,
"name": "TimerSet"
},
"raw_text": "set a timer for 2 hours and 30 minutes",
"raw_tokens": [
"set",
"a",
"timer",
"for",
"2",
"hours",
"and",
"30",
"minutes"
],
"recognize_seconds": 0.6295718450019194,
"slots": {
"hour": [
"value"
],
"minute": [
"value"
]
},
"speech_confidence": 1,
"text": "set a timer for 2 hours and 30 minutes",
"tokens": [
"set",
"a",
"timer",
"for",
"2",
"hours",
"and",
"30",
"minutes"
],
"wakeword_id": null
}
Note that neither the entities nor the slots are correct – I expect to see the values of 2 for ‘hour’ and 30 for ‘minute’, but see only “value”. My JSON format follows the what the docs have posted:
{
"intent": {
"name": "ChangeLightColor",
"confidence": 1.0
},
"entities": [
{ "entity": "name",
"value": "bedroom light" },
{ "entity": "color",
"value": "red" }
],
"text": "set the bedroom light to red"
}
Please advise whether this is an issue on my side or Rhasspy isn’t correctly translating the JSON? Thanks!