Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Noun phrases are used to hold terms with knowledge of proper capitalization and pluralization.
Synopsis
- data CapitalizationRule
- data NP
- type PluralForm = Sentence
- data PluralRule
Types
data CapitalizationRule Source #
Capitalization rules.
For nouns and NounPhrase
s. May be constructed from a
proper noun, common noun, or phrase (Sentence
) and their
respective pluralization and capitalization rules.
ProperNoun String PluralRule | Stores a proper noun and its pluralization. |
CommonNoun String PluralRule CapitalizationRule | Stores a common noun and its pluralization. |
Phrase Sentence PluralForm CapitalizationRule CapitalizationRule | Stores noun phrase and its pluralization. Phrase plurals can get very odd, so it seems best (for now) to encode them directly. FIXME: If the singular/plural phrase has special (replace) capitalization, one of the two cannot be capitalized right now. The two capitalization rules are for sentenceCase / titleCase respectively |
type PluralForm = Sentence Source #
Synonym for Sentence
typically used for plural forms.
data PluralRule Source #
Pluralization rules.