duckling/Duckling
Maíra Bello 328e59ebc4 Quantity/PT: Extend quantity to include grams in portuguese (#631)
Summary:
I'm using Duckling in my project but I noticed that quantities in kg weren't being detected correctly, though other entities such as numeral/volume were all working as expected. Investigating more I noticed that this was just because in Portuguese the Quantity entity was only configured to detect cups and pounds, never grams. And even for cups/pounds, products weren't being detected correctly.

So I've just adapted the rules from English Quantity to work in Portuguese as well, while keeping the cups/pounds too. It's all working as expected now and it's backwards compatible.

Pull Request resolved: https://github.com/facebook/duckling/pull/631

Reviewed By: stroxler

Differential Revision: D29701339

Pulled By: chessai

fbshipit-source-id: fca08a14c50844d418f101b885ca54554d993f58
2021-07-19 15:48:04 -07:00
..
AmountOfMoney Init 2021-05-12 11:32:18 -07:00
CreditCardNumber Relicense to BSD3 2019-05-22 10:46:39 -07:00
Dimensions Init 2021-05-18 13:50:19 -07:00
Distance Add custom isRangeValid implementation for ZH 2021-06-04 12:48:32 -07:00
DistanceUnits Relicense to BSD3 2019-05-22 10:46:39 -07:00
Duration Init 2021-05-12 17:33:54 -07:00
Email Add type=value to JSON response for Email, PhoneNumber and Url 2020-03-18 17:04:42 -07:00
Engine Relicense to BSD3 2019-05-22 10:46:39 -07:00
Numeral ES Numeral - Add ruleLeadingDotNumeral and improve ruleNumeralDotNumeral 2021-07-19 13:18:09 -07:00
Ordinal Russian(RU) numeral and ordinal improvements (#374) 2021-06-04 12:18:31 -07:00
PhoneNumber Add type=value to JSON response for Email, PhoneNumber and Url 2020-03-18 17:04:42 -07:00
Quantity Quantity/PT: Extend quantity to include grams in portuguese (#631) 2021-07-19 15:48:04 -07:00
Ranking Add isArabic rule (#577) 2021-07-12 13:37:23 -07:00
Regex parse latent year intervals 2021-01-29 16:33:56 -08:00
Rules Init 2021-05-18 13:50:19 -07:00
Temperature Init 2021-05-12 14:02:54 -07:00
Testing Simple style fixes for outer layers around Engine.hs 2021-05-06 08:54:56 -07:00
Time Add isArabic rule (#577) 2021-07-12 13:37:23 -07:00
TimeGrain Init 2021-05-12 16:33:51 -07:00
Types Add isArabic rule (#577) 2021-07-12 13:37:23 -07:00
Url Add type=value to JSON response for Email, PhoneNumber and Url 2020-03-18 17:04:42 -07:00
Volume Add rulePrecision2 2021-05-12 16:53:37 -07:00
Api.hs Filter with a self-describing function in where 2021-05-06 08:54:57 -07:00
Core.hs Simple style fixes for outer layers around Engine.hs 2021-05-06 08:54:56 -07:00
Debug.hs In Debug.hs, s/sentence/input/g 2021-05-06 08:54:57 -07:00
Dimensions.hs Initialise Catalan language with Numeral 2021-04-08 14:47:02 -07:00
Engine.hs Make isRangeValid take Lang as input 2021-05-17 13:18:11 -07:00
Locale.hs Initialise Catalan language with Numeral 2021-04-08 14:47:02 -07:00
Region.hs Add a new Arabic locale (EG) (#554) 2020-12-15 11:33:40 -08:00
Resolve.hs Relicense to BSD3 2019-05-22 10:46:39 -07:00
Rules.hs Initialise Catalan language with Numeral 2021-04-08 14:47:02 -07:00
Types.hs Move Candidate to Ranking/Types.hs 2021-05-18 11:50:17 -07:00