Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[German] Skill won't save #163

Closed
jingai opened this issue May 17, 2017 · 28 comments
Closed

[German] Skill won't save #163

jingai opened this issue May 17, 2017 · 28 comments

Comments

@jingai
Copy link
Collaborator

jingai commented May 17, 2017

Getting the totally descriptive, "Error: Failed building the interaction model."

If I cut the AddonExecute and ListenTo* utterances down to one utterance each, it saves. I don't know if the problem is that we've hit a size cap.. or there's a collision that oddly gets through when there's just less to interpret..

If I cut the WhatNew* and CurrentPlay* utterances down to one each, I can add the utterances back in for AddonExecute and ListenToAlbum (but only that one). I guess this hints at size being the problem, but with Amazon's totally cryptic error message.. it's really hard to say.

To confuse things even more.. with the list in the state described above, it's smaller than the English utterances by quite a bit (even with all of the ListenTo* utterances intact), and we don't see this problem with English. So, I considered that maybe it was due to the number of slot references.. but even that doesn't make sense: we have 619 references to slots in the English utterances, vs only 315 for German.

Hopefully that's a starting point, but honestly it would be really helpful if a native speaker could provide some help with this one. It might involve just trimming the utterances some, and if that's the case, I wouldn't really know which ones are suitable to cut.

@mcl22
Copy link

mcl22 commented May 18, 2017

Here's one more wired thing. But perhaps you already know it because you mentioned the alphabetical order before. When I was testing some utterances combinations I first cut the existing ones from my developer account and saved them.
After my testing I copied them back in and it didn't save. It didn't because they were decending from WhatNewShows to AddonExecute. And this doesn't work. So I reordered them and it saved successfully.
But every time I log out from my developers account and then log back in the utterances in the box are in decending order again.
I don't know if that does help anything. I just wanted to mention it because it's wired like the whole thing is.

@mcl22
Copy link

mcl22 commented May 18, 2017

I'd like to help. And I've already started trimming (and correcting) the german utterances. Currently I have a list of 721 entries by just taking out some stuff probably no one would ever say. Therefor I added some new ones. But unfortunately it doesn't save at the moment.
Once it works I also can re-add some utterances. Just because I won't use them doesn't mean nobody would. But for instance I don't think we need things like "when does this episode / part / season / series / tv show / movie / film / video end".

@mcl22
Copy link

mcl22 commented May 23, 2017

Little feedback so far:
Using my trimmed down utterances (1188 items) all intends concerning shows, addons, moviegenres and musicplaylists (i don't have any videoplaylists) work as intended. Those are all slots not containing 300 samples. So what I mean is that it works with the samples given.

I'll now again try to get forward with those slots I do have a lot of items for (movies, artists, songs and albums).

@mcl22
Copy link

mcl22 commented May 23, 2017

So, also the albums seem to work pretty good now. Same "problem" as with movies if i eg I have an album in the sample that's pretty similar to the one asked it could fail. But I guess that one can do nothing about it as long as one doesn't have a db in the back as you mentioned earlier.

I was almost done with testing the albums when I tried to play "Ich mag keine Klassik, aber das gefällt mir!". Alexa understood "öffne kodi und spiele das album ich mag keine klassik aber das gefällt mir" and the result was the answer to CurrentPlayItemTimeRemaining?!
Even though there are a lot of utterances for this intend I don't see any that would be any similar to my demand. Perhaps it's only about what's similar for a pc but the utterances and "spiele das album ich mag keine klassik aber das gefällt mir" are really different. But whatever. Just wanted to mention it :)

@mcl22
Copy link

mcl22 commented May 23, 2017

One thing I discovered by building new utterances:
It all saves until it comes to any What*** intend. Perhaps it's really just accidentaly but I can save any utterances except the WhatAlbums, WhatNewAlbums .... Today I have no more time for that. But I will try more tomottow :)

@mcl22
Copy link

mcl22 commented May 24, 2017

I still have no clue what's going on there with the utterances and slot vlaues. Yesterday I built a new own list of utterances and it would only save if I remove all WhatAlbums and the WhatNewMovies including a {genre} reference.
If I eg reduce my 23 genres to only 4 in the samples I can readd the WhatNewMovies with {genre}. If I add a 5th genre I can't save again.
I don't know it all seems to refer to each other in some wired way. I don't really know what I could try now.

@mcl22
Copy link

mcl22 commented May 26, 2017

I've done a lot of testing and searching on the internet but I don't get much further. Perhaps you can point me to the right direction :)

I currently have these values for my slots:
movies: 300
shows: 89
addons: 1
videoplaylists: 1
musicplaylists: 34
artists: 382
albums: 300
songs: 300
genres: 13-15

I used my own utterances but that shouldn't make a big difference because the problem seems to be the same.
With the above values I can save all utterances if I only add 12 items to the genre slot. If I add one more it won't save.
If I delete one WhatNewMovies utterance without {genre} reference I can add one more item to the genre slot. - Not more.
If I instead delete one WhatNewMovies utterance with {genre} reference I can add 3 more genres so that I then have 15.

So far so good. I did this testing because I thought it could be that I somehow reach some limit and that I reach it faster if I have more utterances that refer to a slot. Perhaps Alexa then tries all possibilities or whatever.

But then I found something that is really wired to me:
As mentioned above I could save more genres if I delete an utterance that refers to a genre. I took this one:
"WhatNewMovies ob wir neue {Genre} Filme haben".
(if we have new {Genre} movies)
Then I re-added this utterance and instead deleted this one:
"WhatNewMovies ob wir einen neuen {Genre} Film haben"
(if we have a new {Genre} movie)
And that didn't save! I mean one is plural, the other one singular. One includes an article ("eine" (= "a")), one does not. But the "eine" has to be in this kind of sentence.

So now I don't know what to test now. I thought I could perhaps find out something like if I take one utterance out that refers to a slot I can add 3 more items to the slots and if I take one out without reference I can only add one. But with this behavior it's impossible. Any ideas?

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

Taking a clue from your testing, I tried removing all references to MOVIEGENRES in both the Intents and Utterances. Unfortunately, it still doesn't save :(

Amazon really needs to provide a debug log rather than just, "Error: Failed building the interaction model." This is utterly frustrating.

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

I've trimmed the comments in this Issue down to just those that are related to this particular problem to make it easier to read in the future.

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

@mcl22, I was in the process of adding the ListenToLatestAlbum intent and encountered this problem with English. After I trimmed all of my slots down to 200 each, it saved again.

Could you try trimming all of your slots down to 200 and see if it helps? If not, try 150, then 100.. make sure to do this to all of them each time. Let me know if there's a number that works.

@mcl22
Copy link

mcl22 commented May 26, 2017

I already do know that 100 works as I had to use this with version 2.5. Nut I will try again.

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

Start with 200 please and make sure to trim all of the slots to that number (unless they already have less than 200).

@mcl22
Copy link

mcl22 commented May 26, 2017

Do you want me to just trim down the ones I have now 300 values in or should I also add values to the slots that only have less than 100 items like genres and addons?

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

No, just trim any that are > 200 down to 200.

@mcl22
Copy link

mcl22 commented May 26, 2017

First result: 200 works with my own utterances, not with the one you provide with the skill. Gonna try further.

@mcl22
Copy link

mcl22 commented May 26, 2017

150 items work with your german utterances.

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

Hmm. Probably could get it to work with 200 if we trimmed up the CurrentPlayItem* and WhatNew* utterances a bit. I did this recently for English and the same could probably be done for German.

Could you do me a huge favor and.. do this? :) I suspect we really don't need 471 CurrentPlayItem* and 164 WhatNew* utterances.

Do bear in mind though, Alexa seems to be a bit more strict about phrasing if a slot is referenced. So, for the WhatNew* utterances that include {Genre}, you might need a few extras there.

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

Have a look at the English phrases for these to give you an idea of what needs to be done.

@mcl22
Copy link

mcl22 commented May 26, 2017

I guess I know what you mean. And actually that was the reason for me to already create all new utterances because on the one hand the german ones do include some that no one would ever say and on the other hand I felt that some are missing.
Of course I can trim them down. (your utterances) but I fear that we will face this problem again and again. As said before with my utterances I ended up with only a single utterance that would make the difference if it saves or not (and it was a question of how many genres I had).
What I mean is, I can now trim them down until they work for me. But perhaps someone else has 3 or 5 genres more than I do and then he's going to run into the same problem I guess. The same for addons or videoplaylists.
I don't know if I mentioned it but a few days ago I just copied the artists into the genres and vice versa. It also saved. But when I added only one item it didn't.
The only thing one could do is decide that there musn't be more than 300 values for each slot, fill them with 300 items and then trim down the utterances until it saves.
But this, I guess, also will only work until, one day you add let's say another (musicgenre) intend or whatever. Correct me if I oversee something :)

@jingai
Copy link
Collaborator Author

jingai commented May 26, 2017

That's just the nature of developing (particularly large) Alexa skills. Until Amazon increases the ceiling on size/whatever, we just have to fight this.

However, we're giving ourselves a bit more headroom by limiting slots to 150 items each.

If possible, could you have a look at utterances.german.txt (rather than SampleUtterances.german.txt)? Ultimately, that's where we need to trim them down. If you can handle parsing that, it'd make my life a lot easier. But I can deal with it either way if you have trouble figuring it out.

@mcl22
Copy link

mcl22 commented May 26, 2017

Actually that's the one I used fo rcreating my own utterances :) I'll trim it down and test it and then send it to you. But maybe only tomorrow because here in Germany it's about 9p.m. and I'm hungry :)

@mcl22
Copy link

mcl22 commented May 27, 2017

I now modified the WhatNew* and CurrentPlay* utterances based on your utterances.german.txt:

CurrentPlayItemInquiry (was/wer) (das ist/ist das)
CurrentPlayItemInquiry was (/gerade/jetzt/gerade jetzt/jetzt gerade/in diesem Moment) (läuft/spielt)
CurrentPlayItemInquiry welche (/Folge/Episode/Serie/Staffel) das ist
CurrentPlayItemInquiry welche (/Folge/Episode/Serie/Staffel) (/gerade/jetzt/gerade jetzt/jetzt gerade/in diesem Moment) (läuft/spielt)
CurrentPlayItemInquiry welcher (/Song) das ist
CurrentPlayItemInquiry welcher (/Song) (/gerade/jetzt/gerade jetzt/jetzt gerade/in diesem Moment) (läuft/spielt)
CurrentPlayItemInquiry welches (/Lied/Video) das ist
CurrentPlayItemInquiry welches (/Lied/Video) (/gerade/jetzt/gerade jetzt/jetzt gerade/in diesem Moment) (läuft/spielt)

CurrentPlayItemTimeRemaining (wann/um wieviel Uhr) ((das/dieses) Video/(der/dieser) Film/(die/diese) (Serie/Episode/Folge)/(das/dieses) Lied) (endet/enden wird/aus sein wird/aus ist/zuende ist)
CurrentPlayItemTimeRemaining wie lang(/e) ((das/dieses) Video/(der/dieser) Film/(die/diese) (Serie/Episode/Folge)/(das/dieses) Lied) (/noch) (ist/geht/läuft)
CurrentPlayItemTimeRemaining wie lange das noch (ist/geht/läuft)

WhatNewAlbums welches neue Album (wartet/(fertig/aufgenommen worden) ist)
WhatNewAlbums welche neuen Alben (warten/(fertig/aufgenommen worden) sind)

WhatNewMovies welcher (/neue) (/{Genre}) Film (wartet/(fertig/aufgenommen worden) ist)
WhatNewMovies welche (/neuen) (/{Genre}) Filme (warten/(fertig/aufgenommen worden) sind)
WhatNewMovies ob es einen neuen (/{Genre}) Film gibt
WhatNewMovies ob wir einen neuen (/{Genre}) Film haben
WhatNewMovies ob es neue (/{Genre}) Filme gibt
WhatNewMovies ob wir neue (/{Genre}) Filme haben

WhatNewShows welche (/neue) Serie (wartet/(fertig/aufgenommen worden) ist)
WhatNewShows welche neuen Serien (warten/(fertig/aufgenommen worden) sind)
WhatNewShows welche (neue Serie/neuen Serien) (habe ich/haben wir/gibt es/ich habe/wir haben/es gibt)

This modified list with to 1233 utterances saves for me with up 150 items / slot. I again add that not all of my slots do have so many entries since I don't have any videoplaylists, only a few addons, some genres and a couple fo tv shows.
If you need me to test it with those slots filled with 150 items, just tell me.

I onyl changed the utterances in a more sensefull way. I say that because, as I already mentioned I'm creating my own one. And that differs a lot from yours. I don't want to blame anyone, but in my opinion the german utterances provided are in some cases, well .... :)
For instance, the WhatNewAlbums only has utterances for "what (new) albums are waiting/were recorded". I would rather ask Alexa to "tell me if there are new albums" or "what new albums do I have". Btw I don't know if anyone still records music :)
For a lot of the WhatNew* utterances the "new" is optional in your file. But I think if I ask for something new I will always say "new". Only exception could be the "recorded" thing which I just modified because I didn't want to change the whole scheme (because perhaps there is a good reason that it was once implemented).
Also things like CurrentPlay... "wie viel länger das noch geht" (how much longer is this): no one would ever say that in german. I guess it was just translated directly from the english sample.

Well, as said before, I don't want to blame anybody. I mean someone did the work and I appreciate that. But I also want to mention that a lot of utterances are not that perfect for the german version. I just wonder if there are so few german users or if they all tweak their utterances or just live with what they got :)

If you are interested I can send you my own utterances once I'm finished with them.

@jingai
Copy link
Collaborator Author

jingai commented May 27, 2017

@mcl22, Unfortunately, the skill still does not save here for me. Are there any other variations you think could be removed?

@jingai
Copy link
Collaborator Author

jingai commented May 27, 2017

@mcl22, if you'd like, you can join us on Slack to chat about things. I'll create a channel there for translation discussion.

@mcl22
Copy link

mcl22 commented May 28, 2017

Ok new try:
CurrentPlayItemInquiry (was/wer) das ist
CurrentPlayItemInquiry was (/gerade/jetzt/jetzt gerade) (läuft/spielt)
CurrentPlayItemInquiry welche (/Folge/Episode/Serie/Staffel) das ist
CurrentPlayItemInquiry welche (/Folge/Episode/Serie/Staffel) (/gerade/jetzt/jetzt gerade) (läuft/spielt)
CurrentPlayItemInquiry welcher (/Song) das ist
CurrentPlayItemInquiry welcher (/Song) (/gerade/jetzt/jetzt gerade) (läuft/spielt)
CurrentPlayItemInquiry welches (/Lied/Video) das ist
CurrentPlayItemInquiry welches (/Lied/Video) (/gerade/jetzt/jetzt gerade) (läuft/spielt)

CurrentPlayItemTimeRemaining (wann/um wieviel Uhr) (das Video/der Film/die (Serie/Episode/Folge)/das Lied) (endet/enden wird/aus sein wird/aus ist/zuende ist)
CurrentPlayItemTimeRemaining wie lang(/e) (das Video/der Film/die (Serie/Episode/Folge)/das Lied) (/noch) (ist/geht/läuft)
CurrentPlayItemTimeRemaining wie lange das noch (ist/geht/läuft)

WhatNewAlbums welches neue Album (wartet/(fertig/aufgenommen worden) ist)
WhatNewAlbums welche neuen Alben (warten/(fertig/aufgenommen worden) sind)

WhatNewMovies welcher (/neue) (/{Genre}) Film (wartet/(fertig/aufgenommen worden) ist)
WhatNewMovies welche (/neuen) (/{Genre}) Filme (warten/(fertig/aufgenommen worden) sind)
WhatNewMovies ob es einen neuen (/{Genre}) Film gibt
WhatNewMovies ob wir einen neuen (/{Genre}) Film haben
WhatNewMovies ob es neue (/{Genre}) Filme gibt
WhatNewMovies ob wir neue (/{Genre}) Filme haben

WhatNewShows welche (/neue) Serie (wartet/(fertig/aufgenommen worden) ist)
WhatNewShows welche neuen Serien (warten/(fertig/aufgenommen worden) sind)
WhatNewShows welche (neue Serie/neuen Serien) (habe ich/haben wir/gibt es/ich habe/wir haben/es gibt)

It's about 200 items less. Tell me if that's ok.

@jingai
Copy link
Collaborator Author

jingai commented May 28, 2017

I'm sorry to say, but it still does not save for me. I have 150 (max) items in the following slots:

MOVIES
SHOWS
MUSICARTISTS
MUSICALBUMS
MUSICSONGS

The others have ~20 each or so. Does this line up with what you have in your copy? If not, I can give you some items to pad your slots if you need, just for testing while you're working on this.

@jingai
Copy link
Collaborator Author

jingai commented May 28, 2017

It works with 100 slot items in each. I'll need to test that the slots still go generic in the English skill.. if they do, we'll push forward like this.

I think the German utterances probably still need more work, but we can deal with that after this.

@jingai
Copy link
Collaborator Author

jingai commented May 28, 2017

English slots are still generic at 100 items each. Changes are all merged into Kodi-Alexa 2.6.2.

@jingai jingai closed this as completed May 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants