duckling/Duckling/Numeral/KM/Corpus.hs
PhalPheaktra Chhaya b541354c31 Add Numeral dimension for new language KM. (#234)
Summary:
Hello,
I am new to Haskell, but I would like to add Khmer language (KM) to Duckling.
I have tried to extended Duckling by adding Numeral dimension for new language KM.
Please have a look at it and see what we can improve.

Thanks!
Pull Request resolved: https://github.com/facebook/duckling/pull/234

Reviewed By: blandinw

Differential Revision: D9032639

Pulled By: chinmay87

fbshipit-source-id: 7db19edf732fe6500629cc89e18e0655d7bbc48b
2018-08-03 14:45:55 -07:00

71 lines
1.5 KiB
Haskell

-- Copyright (c) 2016-present, Facebook, Inc.
-- All rights reserved.
--
-- This source code is licensed under the BSD-style license found in the
-- LICENSE file in the root directory of this source tree. An additional grant
-- of patent rights can be found in the PATENTS file in the same directory.
{-# LANGUAGE OverloadedStrings #-}
module Duckling.Numeral.KM.Corpus
( corpus ) where
import Data.String
import Prelude
import Duckling.Locale
import Duckling.Numeral.Types
import Duckling.Resolve
import Duckling.Testing.Types
context :: Context
context = testContext {locale = makeLocale KM Nothing}
corpus :: Corpus
corpus = (context, testOptions, allExamples)
allExamples :: [Example]
allExamples = concat
[ examples (NumeralValue 0)
[ "0"
, ""
]
, examples (NumeralValue 1)
[ "1"
, ""
]
, examples (NumeralValue 2)
[ "2"
, ""
]
, examples (NumeralValue 3)
[ "3"
, ""
]
, examples (NumeralValue 4)
[ "4"
, ""
]
, examples (NumeralValue 5)
[ "5"
, ""
]
, examples (NumeralValue 6)
[ "6"
, ""
]
, examples (NumeralValue 7)
[ "7"
, ""
]
, examples (NumeralValue 8)
[ "8"
, ""
]
, examples (NumeralValue 9)
[ "9"
, ""
]
]