snipsco / snips-nlu

Snips Python library to extract meaning from text
https://snips-nlu.readthedocs.io
Apache License 2.0
3.89k stars 513 forks source link

Add key hashing to Lookup Intent Parser for perf #766

Closed mattgathu closed 5 years ago

mattgathu commented 5 years ago

Description:

Use hashes as dictionary keys instead of actual strings. This reduces the size of the model.

Add utility function to handle key deserialization from JSON.

Checklist:

codecov-io commented 5 years ago

Codecov Report

Merging #766 into feature/lookup_intent_parser will increase coverage by 0.01%. The diff coverage is 100%.

@@                       Coverage Diff                        @@
##           feature/lookup_intent_parser     #766      +/-   ##
================================================================
+ Coverage                         88.47%   88.48%   +0.01%     
================================================================
  Files                                75       75              
  Lines                              4711     4716       +5     
  Branches                            893      895       +2     
================================================================
+ Hits                               4168     4173       +5     
  Misses                              401      401              
  Partials                            142      142
codecov-io commented 5 years ago

Codecov Report

Merging #766 into feature/lookup_intent_parser will increase coverage by 0.01%. The diff coverage is 100%.

@@                       Coverage Diff                        @@
##           feature/lookup_intent_parser     #766      +/-   ##
================================================================
+ Coverage                         88.47%   88.48%   +0.01%     
================================================================
  Files                                75       75              
  Lines                              4711     4716       +5     
  Branches                            893      895       +2     
================================================================
+ Hits                               4168     4173       +5     
  Misses                              401      401              
  Partials                            142      142