snipsco / snips-nlu-rs

Snips NLU rust implementation
https://snips.ai
Other
340 stars 56 forks source link

trained_assistant.json file downloaded from the website (in zip) seems to break things #13

Closed fjlaubscher closed 6 years ago

fjlaubscher commented 6 years ago

Hey!

I've been hacking around for a while now using the example in this repo to get up and running and had an issue earlier where it would break when I tried to parse a query. More specifically thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: InvalidLength', libcore/result.rs:945:5

I then ran a backtrace and tracked it down to lib/src/intent_parser/probabilistic_intent_parser.rs:50. Afterwards, I decided to try the trained_assistant.json file in the examples directory and everything worked fine which leads me to believe the trained_assistant.json file in the zip file, which I've downloaded from snips.ai, was faulty.

I also spotted these older version numbers in the zip file version which are different to the example versions. "training_package_version": "0.11.2", "model_version": "0.12.0"

See this gist which shows my code Not sure if that helps at all?

Like I mentioned, I'm up and running now using the example file, just thought I'd mention it here.

I already bombarded your Discord NLU channel too 🎉

adrienball commented 6 years ago

Hi @fjlaubscher, Thanks for reporting this issue. console.snips.ai currently uses a previous version of the training (which is incompatible with the latest version of this repo), which explains your issue. This PR, once merged and released, will improve the error message in this specific case.

A new version is to be deployed on console.snips.ai soon, and will match the one of the example. For the future, we will try to have a way for the end user to easily know which version of training + inference to use, and how to fix versions mismatch when they occur.

knyastasia commented 6 years ago

Hi @adrienball Running into the same issue. I'm using the latest release (0.54.0) of this repo and it doesn't contain your error message improvement, can you bump it up, please?

Also, which release/commit can I use for model version 0.12.0?

Thanks!

UPD: actually, nevermind. I got a newer model version. Thanks!