lib/zenlish/lang/dictionary.rb in zenlish-0.2.04 vs lib/zenlish/lang/dictionary.rb in zenlish-0.2.05
- old
+ new
@@ -9,11 +9,11 @@
sandbox = Object.new
sandbox.extend(Zenlish::Lex::EmptyLexiconFactory)
Dictionary = sandbox.create_empty_lexicon
self.extend(Feature::FeatureStructDefBearer)
- # @param aLemma [String] is the canonical form, dictionary form,
+ # @param aLemma [String] is the canonical form, dictionary form,
# or citation form of a headword.
# @param aWClassName [String] the name of a word class.
def self.add_entry(aLemma, aWClassName, aFeatureHash = nil, &aBlock)
entry = Zenlish::Lex::LexicalEntry.new(aLemma)
wclass = Dictionary.name2terminal[aWClassName]
@@ -63,13 +63,13 @@
add_entry('choose', 'IrregularVerb') do
forms past_simple: 'chose', past_participle: 'chosen'
end
add_entry('contain', 'RegularVerb')
add_entry('container', 'CommonNoun')
- add_entry('damage', 'RegularVerb')
+ add_entry('damage', 'RegularVerb')
add_entry('die', 'RegularVerb')
- add_entry('difficult', 'Adjective')
+ add_entry('difficult', 'Adjective')
add_entry('different', 'Adjective')
add_entry('do', 'AuxiliaryDo')
add_entry('do', 'IrregularVerbDo')
add_entry('each', 'DistributiveDeterminer')
add_entry('each', 'Pronoun')
@@ -90,16 +90,19 @@
end
add_entry('here', 'Adverb')
# example: ...from here (works as a pronoun of a place)
add_entry('here', 'CommonNoun', {'NUMBER' => enumeration(:singular),
'PARADIGM' => [identifier, 'Singular_only']})
- add_entry('I', 'PersonalPronoun')
+ add_entry('I', 'PersonalPronoun', { 'PERSON' => enumeration(:first),
+ 'GENDER' => enumeration(:feminine, :masculine) })
add_entry('if', 'SubordinatingConjunction')
add_entry('in', 'Preposition')
add_entry('inside', 'Preposition')
- add_entry('it', 'PersonalPronoun')
- add_entry('its', 'PossessiveDeterminer')
+ add_entry('it', 'PersonalPronoun', { 'PERSON' => enumeration(:third),
+ 'PARADIGM' => [identifier, 'ppn_3rd_paradigm']})
+ add_entry('its', 'PossessiveDeterminer', { 'PERSON' => enumeration(:third),
+ 'PARADIGM' => [identifier, 'possdet_3rd_paradigm']})
add_entry('kind', 'CommonNoun')
add_entry('know', 'IrregularVerbKnow') do
forms past_simple: 'knew', past_participle: 'known'
end
add_entry('like', 'Preposition')
@@ -110,17 +113,17 @@
add_entry('make', 'IrregularVerb') do
forms past_simple: 'made', past_participle: 'made'
end
add_entry('many', 'Quantifier')
add_entry('maybe', 'AdverbMaybe')
- add_entry('me', 'PersonalPronoun')
add_entry('moment', 'CommonNoun')
add_entry('more', 'Adjective')
add_entry('more', 'Adverb')
add_entry('move', 'RegularVerb')
add_entry('much', 'Adverb')
- add_entry('my', 'PossessiveDeterminer')
+ add_entry('my', 'PossessiveDeterminer',{ 'PERSON' => enumeration(:first),
+ 'GENDER' => enumeration(:feminine, :masculine)})
add_entry('near', 'Preposition')
add_entry('near to', 'Preposition')
add_entry('now', 'Adverb')
add_entry('now', 'CommonNoun', {'NUMBER' => enumeration(:singular),
'PARADIGM' => [identifier, 'Singular_only']})
@@ -131,11 +134,11 @@
add_entry('one', 'Cardinal')
add_entry('one', 'IndefinitePronoun')
add_entry('or', 'Coordinator')
add_entry('other', 'Adjective')
add_entry('part', 'CommonNoun')
- add_entry('people', 'CommonNoun', {'NUMBER' => enumeration(:plural),
+ add_entry('people', 'CommonNoun', {'NUMBER' => enumeration(:plural),
'PARADIGM' => [identifier, 'Plural_only']})
add_entry('person', 'CommonNoun', {'NUMBER' => enumeration(:singular),
'PARADIGM' => [identifier, 'Singular_only']})
add_entry('place', 'CommonNoun')
add_entry('same', 'Adjective')
@@ -155,15 +158,12 @@
add_entry('something', 'IndefinitePronoun')
add_entry('surface', 'CommonNoun')
add_entry('than', 'PrepositionThan')
add_entry('that', 'RelativePronoun')
add_entry('the', 'DefiniteArticle')
- add_entry('them', 'PersonalPronoun')
add_entry('then', 'LinkingAdverb')
- add_entry('their', 'PossessiveDeterminer')
add_entry('there', 'ExistentialThere')
- add_entry('they', 'PersonalPronoun')
add_entry('thing', 'CommonNoun')
add_entry('think', 'IrregularVerbThink') do
forms past_simple: 'thought', past_participle: 'thought'
end
add_entry('this', 'DemonstrativeDeterminer')
@@ -184,11 +184,15 @@
add_entry('where', 'Adverb')
add_entry('where', 'SubordinatingConjunction')
add_entry('who', 'RelativePronoun')
add_entry('with', 'Preposition')
add_entry('word', 'CommonNoun')
- add_entry('you', 'PersonalPronoun')
- add_entry('your', 'PossessiveDeterminer')
+ add_entry('you', 'PersonalPronoun', { 'PERSON' => enumeration(:second),
+ 'GENDER' => enumeration(:feminine, :masculine),
+ 'PARADIGM' => [identifier, 'ppn_2nd_paradigm']})
+ add_entry('your', 'PossessiveDeterminer', { 'PERSON' => enumeration(:second),
+ 'GENDER' => enumeration(:feminine, :masculine),
+ 'PARADIGM' => [identifier, 'possdet_2nd_paradigm']})
# Punctuation signs...
add_entry(':', 'Colon')
add_entry(',', 'Comma')
add_entry('.', 'Period')
\ No newline at end of file