Commit Graph

11 Commits

Author SHA1 Message Date
Igor Kuzmenko
9993911e3b Adds UAH currency Type and examples to EN and RU Corpus (#433)
Summary:
This PR adds UAH currency Type and examples to EN and RU Corpus

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

Reviewed By: girifb

Differential Revision: D25102990

Pulled By: chessai

fbshipit-source-id: ed40e8dfcf145a65c7e6d87158da0efacb32e256
2021-02-01 14:32:24 -08:00
Julien Odent
bf89e34365 Relicense to BSD3
Reviewed By: JoelMarcey

Differential Revision: D15439223

fbshipit-source-id: c5af3cb06318748142fe503945b38beffadfc28a
2019-05-22 10:46:39 -07:00
Albert Morgese
2ace5d474b AmountOfMoney/EN: Add basic latent support
Summary: Implemented basic latent value support for AmountOfMoney (along with a corpus).  Currently only supports raw numbers.

Reviewed By: chinmay87

Differential Revision: D9777183

fbshipit-source-id: 16a454d451b74ddc526e0db1ddc9b4959b677ca6
2018-09-12 15:30:58 -07:00
Daniel Sainati
3910c68262 AmountOfMoney/EN: added support for subunits of dollars
Summary: Added support for recognizing nickels, dimes and quarters, as well as numbers of coins.

Reviewed By: patapizza

Differential Revision: D9317706

fbshipit-source-id: 3fb3d63546c9cfe13c094703ddb583c6ac46585b
2018-08-16 15:45:43 -07:00
RIAN DOUGLAS
a38794c7c4 Changes uses of 'financeWith' to use 'isSimpleAmountOfMoney' or 'isCurrencyOnly'
Summary: Changes uses of the financeWith function to use more specific methods which check for either a simple value, or only a currency, making the intent clearer

Reviewed By: haoxuany

Differential Revision: D8064995

fbshipit-source-id: 7321a4482aad8dbdbc7d734eb393220873ad0b51
2018-05-19 18:00:26 -07:00
Aaron Yue
4df76289bc Implement AmountOfMoney
Summary: implement AmountOfMoney rules and corpus for ZH

Reviewed By: patapizza

Differential Revision: D7508507

fbshipit-source-id: 3591b399a9880c5278587979c6576720343cc123
2018-04-17 16:45:32 -07:00
Aaron Yue
e542ff5b50 Distribute ruleUnitAmount to all languages
Summary:
enforce units are checked in ruleUnitAmount and ruleAmountUnit, and distribute ruleUnitAmount to all
languages, since in some languages this doesn't work (such as for ZH, where value units must succeed amounts)

Reviewed By: patapizza

Differential Revision: D7509840

fbshipit-source-id: 3a79b39721850f9d0289442925fbc02cf69abefb
2018-04-05 10:45:35 -07:00
Julien Odent
b00fa512af AmountOfMoney: fixes
Summary:
* don't recursively compose cents
* don't allow decreasing ranges

Reviewed By: blandinw

Differential Revision: D6849132

fbshipit-source-id: ed6ca30388642c21e677a628971747a4fb3dfbef
2018-01-30 14:45:36 -08:00
Julien Odent
bef7a44fa8 Remove redundant brackets and language pragmas
Summary: .

Reviewed By: JonCoens

Differential Revision: D6838082

fbshipit-source-id: 94757bdb80c6d3c29a7a6554429940a1b7403108
2018-01-29 16:45:28 -08:00
Julien Odent
b943111b4f Intervals for AmountOfMoney
Summary:
* Supports "a" + currency (e.g. "a dollar")
* Supports intervals (e.g. "10-20 dollars")
* Supports open intervals (e.g. "above 3 dollars", "less than 3 dollars")
* Follows `Time` format

Reviewed By: blandinw

Differential Revision: D5233766

fbshipit-source-id: 57cb6a8
2017-06-13 16:34:21 -07:00
Julien Odent
e76cee3a6d Rename Finance to AmountOfMoney
Summary: Because it makes more sense.

Reviewed By: JonCoens

Differential Revision: D4721646

fbshipit-source-id: 449bfb4
2017-03-16 14:49:44 -07:00