snipsco / snips-issues

Feel free to share your bugs with us.
14 stars 5 forks source link

[NLU] built-in intent Snips/datetime does not recognize "morgen" (tomorrow) #124

Closed shilbert01 closed 5 years ago

shilbert01 commented 5 years ago

What's the issue? The built-in intent snips/datetime does not recognize "morgen" (tomorrow) but "übermorgen" (day after tomorrow)

Use Cases Impacted My app does not understand that I want information about tomorrow ("morgen in German)" It works when typing the question in the snips console but not when speaking it in the snips console. The slot is omitted for "morgen" but not for "übermorgen"

How to reproduce Install the app Stundenplan and ask two questions. 1) Welche Stunden habe ich morgen 2) Welche Stunden habe ich übermorgen

Expected behavior It should translate "morgen" into the date for tomorrow.

Version and Environment OS version ................... Raspbian GNU/Linux 9 (stretch) Installed assistant .......... Smarthome_B Language ..................... de Hotword ...................... hey_snips ASR engine ................... snips Status ....................... Live

Service status:

snips-analytics .............. 0.62.3 (not running) snips-asr .................... 0.62.3 (running) snips-audio-server ........... 0.62.3 (running) snips-dialogue ............... 0.62.3 (running) snips-hotword ................ 0.62.3 (running) snips-nlu .................... 0.62.3 (running) snips-skill-server ........... 0.62.3 (running) snips-tts .................... 0.62.3 (running)

Logs Additional information

"morgen"
[11:05:45] [Hotword] detected on site snipssat2, for model hey_snips
[11:05:45] [Asr] was asked to stop listening on site snipssat2
[11:05:45] [Hotword] was asked to toggle itself 'off' on site snipssat2
[11:05:45] [Dialogue] session with id '47d68120-d843-443c-9306-ec1a67d95add' was started on site snipssat2
[11:05:45] [AudioServer] was asked to play a wav of 41.1 kB with id '23f91f60-1dfd-4f68-9554-a2687419f592' on site snipssat2
[11:05:46] [AudioServer] finished playing wav with id '23f91f60-1dfd-4f68-9554-a2687419f592'
[11:05:46] [Asr] was asked to listen on site snipssat2
[11:05:50] [Asr] captured text "welche stunden habe ich morgen" in 4.0s
[11:05:50] [Asr] was asked to stop listening on site snipssat2
[11:05:50] [AudioServer] was asked to play a wav of 93.1 kB with id 'e8f69e92-0234-4370-9e43-6760ecfb6fe6' on site snipssat2
[11:05:51] [AudioServer] finished playing wav with id 'e8f69e92-0234-4370-9e43-6760ecfb6fe6'
[11:05:51] [Nlu] was asked to parse input "welche stunden habe ich morgen"
[11:05:51] [Nlu] detected intent shilbert:GetTimetableForDay with confidence score 0.985 for input "welche stunden habe ich morgen"
[11:05:51] [Dialogue] New intent detected shilbert:GetTimetableForDay with confidence 0.985
[11:05:51] [Nlu] was asked to parse input "welche stunden habe ich morgen"
[11:05:51] [Nlu] detected intent shilbert:GetTimetableForDay with confidence score 0.985 for input "welche stunden habe ich morgen"
[11:05:57] [Dialogue] session with id '47d68120-d843-443c-9306-ec1a67d95add' was ended on site snipssat2. The session was ended because one of the component didn't respond in a timely manner
[11:05:57] [Asr] was asked to stop listening on site snipssat2
[11:05:57] [Hotword] was asked to toggle itself 'on' on site snipssat2

vs. "übermorgen"
[11:06:39] [Hotword] detected on site snipssat2, for model hey_snips
[11:06:39] [Asr] was asked to stop listening on site snipssat2
[11:06:39] [Hotword] was asked to toggle itself 'off' on site snipssat2
[11:06:39] [Dialogue] session with id 'e8bc161c-bffe-4240-aa2c-a0f631992b00' was started on site snipssat2
[11:06:39] [AudioServer] was asked to play a wav of 41.1 kB with id '4ebb181c-5beb-4c4d-addb-b847e83fe49e' on site snipssat2
[11:06:40] [AudioServer] finished playing wav with id '4ebb181c-5beb-4c4d-addb-b847e83fe49e'
[11:06:40] [Asr] was asked to listen on site snipssat2
[11:06:44] [Asr] captured text "welche stunden habe ich übermorgen" in 4.0s
[11:06:44] [Asr] was asked to stop listening on site snipssat2
[11:06:44] [AudioServer] was asked to play a wav of 93.1 kB with id 'dbeed831-8f43-4310-af41-a931f14c38e9' on site snipssat2
[11:06:45] [AudioServer] finished playing wav with id 'dbeed831-8f43-4310-af41-a931f14c38e9'
[11:06:45] [Nlu] was asked to parse input "welche stunden habe ich übermorgen"
[11:06:45] [Nlu] detected intent shilbert:GetTimetableForDay with confidence score 0.973 for input "welche stunden habe ich übermorgen"
              Slots ->
                 day -> 2019-04-25 00:00:00 +02:00 (confidence: 0.915)
[11:06:45] [Dialogue] New intent detected shilbert:GetTimetableForDay with confidence 0.973
              Slots ->
                 day -> 2019-04-25 00:00:00 +02:00 (confidence: 0.915)
[11:06:46] [Nlu] was asked to parse input "welche stunden habe ich übermorgen"
[11:06:46] [Nlu] detected intent shilbert:GetTimetableForDay with confidence score 0.973 for input "welche stunden habe ich übermorgen"
              Slots ->
                 day -> 2019-04-25 00:00:00 +02:00 

Workaround Name the day explicetly (e.g. Wednesday) instead of tomorrow.

ClemDoum commented 5 years ago

@shilbert01 I see the bug in the device logs, but do you also have the bug in the console ? I can't reproduce it in the console on my side. Here is my setup:

Here is the output of the console when when pronouncing (not typing): Welche Stunden habe ich morgen Screen Shot 2019-04-25 at 14 58 57

ClemDoum commented 5 years ago

@shilbert01 in case you see the bug on your side:

shilbert01 commented 5 years ago

I have other apps in my assistant. I will try standalone. Feel free to downlaod the assistant and app. It is is the app store.

On Thu, Apr 25, 2019 at 3:26 PM Clément Doumouro notifications@github.com wrote:

@shilbert01 https://github.com/shilbert01 in case you see the bug on your side:

  • do you have other apps in your assistant ?
  • do you allow me to download your assistant, to reproduce the bug on my machine and do some advanced debugging ?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/snipsco/snips-issues/issues/124#issuecomment-486671984, or mute the thread https://github.com/notifications/unsubscribe-auth/AKCWIHTOJ6YBFQ4U2DANYLLPSGWSFANCNFSM4HHV6RRQ .

jenskastensson commented 5 years ago

We are seeing similar problems with builtin slot type for the built-in snips/datetime in German When we add some training examples in German and test them in the console (enter text): "um 8 uhr" returns no slots "in10 minuten" returns no slots "um 16 Uhr 30" returns no slots

Another problem is "in 1 Stunde" is treated as "um ein Stunde" "in 1 Minute" is treated as "um ein Stunde"

Platform Version, OS, Assistant installed, etc.. Platform Version: Snips 0.62.3 OS: Raspbian 9 Stretch

rosastern commented 5 years ago

Hi @jenskastensson ,

This looks like a different issue.

First you say "duration" and then mention the slot type snips/datetime - which one are you using? For your examples it would be snips/datetime indeed, not snips/duration. On our end all these cases are recognized correctly. Could you check if you're using the right slot type?

If you still have issues, feel free to open a new ticket so that we can investigate.

jenskastensson commented 5 years ago

The problem is related to snips/datetime in German. When I test the following strings in the console, none of them works as expected (slots are empty) "um 8 uhr" returns no slots "in10 minuten" returns no slots "um 16 Uhr 30" returns no slots "in 1 Stunde" is treated as "um ein Stunde" "in 1 Minute" is treated as "um ein Stunde"

jenskastensson commented 5 years ago

The training examples:

weck mich in [1 Stunde](time)
Weck mich morgen um [16 Uhr 30](time)
Wecke mich um [8 uhr](time)
Einen Timer [in 8 minuten](time) einstellen

time === snips/datetime

rosastern commented 5 years ago

OK, for

weck mich in [1 Stunde](time)
Weck mich morgen um [16 Uhr 30](time)
Wecke mich um [8 uhr](time)

the preposition (in or um) needs to be part of the slot. The last example where this is the case should work correctly.

This is indeed a problem related to snips/datetime in German, but not exactly the same issue as the one for which the ticket was opened, so if still needed a new ticket would be very useful to deal with this one the best we can.

jenskastensson commented 5 years ago

Thank you @rosastern , the problem was indeed the prepositions, when we move them inside the slot all works. Thank you for the support!