Interset/Tagset/HE/Conll.pm untested

filter: Statementstmt 0.0% 0 / 282 Branchbran 0.0% 0 / 6 Conditioncond 0.0% 0 / 3 MC/DCmcdc n/a Subroutinesub 0.0% 0 / 13 Podpod 0.0% 0 / 7 totaltotal 0.0% 0 / 311 CC 4 SCAR 14.8
CC
4
Cov
0%
encode
12.0
decode
6.0
get_tagset_id
2.0
CRAP 4.4
1 # ABSTRACT: Driver for the Hebrew tagset.
2 # Copyright © 2014, 2017 Dan Zeman <zeman@ufal.mff.cuni.cz>
3 # Copyright © 2013 Rudolf Rosa <rosa@ufal.mff.cuni.cz>
4  
5 package Lingua::Interset::Tagset::HE::Conll;
6 use strict;
7 use warnings;
8 our $VERSION = '3.014';
9  
10 use utf8;
11 use open ':utf8';
12 use namespace::autoclean;
13 use Moose;
14 extends 'Lingua::Interset::Tagset::Conll';
15  
16  
17  
18 #------------------------------------------------------------------------------
19 # Returns the tagset id that should be set as the value of the 'tagset' feature
20 # during decoding. Every derived class must (re)define this method! The result
21 # should correspond to the last two parts in package name, lowercased.
22 # Specifically, it should be the ISO 639-2 language code, followed by '::' and
23 # a language-specific tagset id. Example: 'cs::multext'.
24 #------------------------------------------------------------------------------
25 sub get_tagset_id
26 {
27 return 'he::conll';
28 }
29  
30  
31  
32 #------------------------------------------------------------------------------
33 # Creates atomic drivers for surface features.
34 #------------------------------------------------------------------------------
35 sub _create_atoms
36 {
37 my $self = shift;
38 my %atoms;
39 # PART OF SPEECH ####################
40 # Yoav Goldberg:
41 # The tagging conversion was done in a semi-automated process (a heuristic
42 # mapping between the tagsets, which accounts for the tree context, was
43 # defined and applied. Some hard cases were left unresolved in the automatic
44 # process and marked for manual annotation). Words that lack an analysis in
45 # the Morphological Analyzer are assigned the tag !!UNK!!, and words that do
46 # not have a correct analysis in the morphological analyzer are assigned the
47 # tag !!MISS!!
48 $atoms{pos} = $self->create_atom
49 (
50 'surfeature' => 'pos',
51 'decode_map' =>
52 {
53 # Adverb appearing as prefix
54 # כ
55 'ADVERB' => ['pos' => 'adv', 'other' => {'advtype' => 'prefix'}],
56 # AT (direct object) marker
57 # תא
58 'AT' => ['pos' => 'part'],
59 # There are two ways of tagging participles:
60 # BN (or BN_S_PP or BNT) part of speech ... we decode it as 'adj|verb'.
61 # VB part of speech, BEINONI feature ... we decode it as 'verb'.
62 # Beinoni (participle) form
63 # רושק, ףסונ, עגונ, רבודמ
64 'BN' => ['pos' => 'adj|verb', 'verbform' => 'part'],
65 # Beinoni Form with a possessive suffix
66 # היבשוי
67 'BN_S_PP' => ['pos' => 'adj|verb', 'verbform' => 'part', 'poss' => 'yes'],
68 # Construct-state Beinoni Form
69 # עבטמ, הברמ, תלזוא, יליחנמ, יכומ
70 'BNT' => ['pos' => 'adj|verb', 'verbform' => 'part', 'definite' => 'cons'],
71 # Conjunction
72 # ש, דוגינב, לככ, יפכ
73 'CC' => ['pos' => 'conj'],
74 # Coordinating Conjunction other than ו
75 # םג, םא, וא, לבא, קר
76 'CC-COORD' => ['pos' => 'conj', 'conjtype' => 'coor'],
77 # Relativizing Conjunction
78 # אשר ašər אֲשֶׁר = which, that, who
79 'CC-REL' => ['pos' => 'conj', 'prontype' => 'rel'],
80 # Subordinating Conjunction
81 # יכ, ידכ, רחאל, רשאכ, ומכ
82 'CC-SUB' => ['pos' => 'conj', 'conjtype' => 'sub'],
83 # Number
84 # תחא, 1, 0
85 'CD' => ['pos' => 'num'],
86 # Construct Numeral
87 # ינש, יתש, יפלא, תואמ, תורשע
88 'CDT' => ['pos' => 'num', 'definite' => 'cons'],
89 # The ו coordinating word
90 # ו (wa) = and ... 3707 occurrences; but why is it not CC-COORD? (35 occs. is CC but not CC-COORD.)
91 # We will decode it but we will not list it as a known tag and we will encode CC-COORD back.
92 'CONJ' => ['pos' => 'conj', 'conjtype' => 'coor'],
93 # Copula (present) and Auxiliaries (past and future)
94 # היה, ויה, התיה, וניא, היהי
95 'COP' => ['pos' => 'verb', 'verbtype' => 'cop'],
96 #89 COP-TOINFINITIVE
97 'COP-TOINFINITIVE' => ['pos' => 'verb', 'verbtype' => 'cop', 'verbform' => 'inf'],
98 # H marker (the definite article prefix: 15847 occurrences)
99 # ה
100 'DEF' => ['pos' => 'adj', 'prontype' => 'art', 'definite' => 'def'],
101 #53 DEF@DT הכל (hkl) = "everything", 46 occurrences
102 'DEF@DT' => ['pos' => 'adj', 'definite' => 'def', 'prontype' => 'tot'],
103 # Determiner
104 # יהשוזיא, רחבמ, לכ
105 'DT' => ['pos' => 'adj', 'prontype' => 'prn'],
106 # Construct-state Determiner
107 # המכ, ותוא, םוש, הברה
108 'DTT' => ['pos' => 'adj', 'prontype' => 'prn', 'definite' => 'cons'],
109 # Existential
110 # שי, ןיא, םנשי, היה
111 'EX' => ['pos' => 'adv', 'advtype' => 'ex'],
112 # Preposition
113 # לע, ל, םע, ןיב
114 'IN' => ['pos' => 'adp|conj', 'adpostype' => 'prep', 'conjtype' => 'sub'],
115 # Interjection
116 # סופ, ףוא, הלילח, אנ, יוא
117 'INTJ' => ['pos' => 'int'],
118 # Adjective
119 # םירחא, םיבר, שדח, לודג, ימואל
120 'JJ' => ['pos' => 'adj'],
121 # Construct-state Adjective
122 # רבודמ, יעדומ, ילוער, תרסח, יבורמ
123 'JJT' => ['pos' => 'adj', 'definite' => 'cons'],
124 # Modal
125 # רשפא, לוכי, ךירצ, הלוכי, לולע
126 'MD' => ['pos' => 'verb', 'verbtype' => 'mod'],
127 # Numerical Expression: dates, times and other codes composed of numbers and dots.
128 # 03.02, 00.02, 11.61, 28.6.6, 11.31
129 'NCD' => ['pos' => 'num', 'numform' => 'digit'],
130 # Noun
131 # הרטשמ, הלשממ, םוי, ץרא
132 'NN' => ['pos' => 'noun', 'nountype' => 'com'],
133 # Proper Nouns
134 # לארשי, םילשורי, אנהכ, ביבא
135 'NNP' => ['pos' => 'noun', 'nountype' => 'prop'],
136 # Noun with a possessive suffix
137 # ותומ, וירבד, וייח, ופוס, ומש
138 'NN_S_PP' => ['pos' => 'noun', 'poss' => 'yes'],
139 # Construct-state nouns
140 # ידי, תעדוו
141 'NNT' => ['pos' => 'noun', 'definite' => 'cons'],
142 # “Prefix” wordlets
143 # בלתי, אי, בין, אנטי, תת
144 # 22 different word forms in the corpus.
145 # 47 occurrences of the most frequent one, בלתי (vlty).
146 'P' => ['pos' => 'part', 'other' => {'parttype' => 'prefix'}],
147 # Possessive
148 # לש
149 'POS' => ['pos' => 'part', 'poss' => 'yes'],
150 # Prefix-Prepositions
151 # ב, ל, מ, כ, שכ
152 'PREPOSITION' => ['pos' => 'adp', 'adpostype' => 'prep'],
153 # Pronouns TODO prontype?
154 # אוה, הז, איה, םה, וז
155 'PRP' => ['pos' => 'noun', 'prontype' => 'prs'],
156 #222 PRP-DEM
157 'PRP-DEM' => ['pos' => 'adj', 'prontype' => 'dem'],
158 #2 PRP-IMP
159 # כְּלוּם kəlum = anything PRP PRP-IMP _
160 # Used with a negative word, so the combination means "nothing".
161 'PRP-IMP' => ['pos' => 'noun', 'prontype' => 'neg'],
162 # Punctuation
163 # ,, ., ־
164 'PUNC' => ['pos' => 'punc'],
165 # QuestionWord
166 # המ, ימ, םאה, מ, ןכיה
167 'QW' => ['pos' => 'adj', 'prontype' => 'int'],
168 # Adverbs
169 # אל, רתוי, דוע, רבכ, לומתא
170 'RB' => ['pos' => 'adv'],
171 # Relativizer
172 # ש
173 'REL-SUBCONJ' => ['pos' => 'adj', 'prontype' => 'rel'],
174 # Nominative suffix
175 # F|P|3: הן~ (-hen)
176 # F|S|3: היא~ (-hya)
177 # M|P|3: הם~ (-hem)
178 # M|S|2: אתה~ (-ath)
179 # M|S|3: הוא~ (-hwa)
180 'S_ANP' => ['pos' => 'part', 'case' => 'nom'],
181 # Pronomial suffix TODO prontype?
182 # suffאוה, suffמה, suffאיה
183 # F|M|P|1: אנחנו~ (-anaxnú)
184 # F|M|S|1: אני~ (-aní)
185 # F|P|3: הן~ (-hen)
186 # F|S|2: את~ (-at)
187 # F|S|3: היא~ (-hya)
188 # M|P|2: אתם~ (-atm)
189 # M|P|3: הם~ (-hem)
190 # M|S|2: אתה~ (-ath)
191 # M|S|3: הוא~ (-hwa)
192 'S_PRN' => ['pos' => 'part', 'prontype' => 'prs'],
193 # Temporal Suboordinating Conjunction
194 # כש (kš) = when ... 111 occurrences
195 # מש (mš) = duration ... 2 occurrences
196 'TEMP-SUBCONJ' => ['pos' => 'conj', 'conjtype' => 'sub', 'advtype' => 'tim'],
197 # Titles
198 # ד"ר (d"r) = Dr. ... TTL S, 24 occurrences
199 # עו"ד (ew"d) = Attorney ... TTL S, 11 occurrences
200 # זצ"ל (zc"l, zexer cadik livraxa) = holy/righteous person in judaism ... TTL S, 1 occurrence
201 # ניצב (nycv) = commander ... TTL M|S, 9 occurrences
202 # פרופסור (profsor) = proffessor ... TTL M|S, 4 occurrences
203 # מר (mr) = Mr. ... TTL M|S, 4 occurrences
204 # ז"ל (z"l) = late ... TTL M|F|S|P, 3 occurrences
205 # A shorthand way of writing זכרונו\ה\ם\ן לברכה (zikhronó/á/ám/án livrakhá), which means “may his/her/their memory be a blessing”.
206 # The abbreviation ז״ל is nearly always read out as the two words it stands for.
207 # This means that its pronunciation depends on whether the referent is a woman, a man, multiple women, or multiple men and women.
208 # It is, however, also pronounced /zal/.
209 'TTL' => ['pos' => 'noun', 'other' => {'nountype' => 'title'}],
210 # Verbs
211 # רמא, רמוא, הארנ, עדוי
212 'VB' => ['pos' => 'verb'],
213 #1 VB-BAREINFINITIVE
214 'VB-BAREINFINITIVE' => ['pos' => 'verb', 'verbform' => 'inf'],
215 # Infinitive Verbs
216 # תושעל, םלשל, עונמל, תתל, עצבל
217 'VB-TOINFINITIVE' => ['pos' => 'verb', 'verbform' => 'inf', 'other' => {'infinitive' => 'to'}],
218 #550 !!MISS!!
219 # words that do not have a correct analysis in the morphological analyzer
220 '!!MISS!!' => ['other' => {'unknown' => 'miss'}],
221 #6 !!SOME_!!
222 '!!SOME_!!' => ['other' => {'unknown' => 'some'}],
223 #520 !!UNK!!
224 # Words that lack an analysis in the Morphological Analyzer
225 '!!UNK!!' => ['other' => {'unknown' => 'unk'}],
226 #134 !!ZVL!!
227 '!!ZVL!!' => ['other' => {'unknown' => 'zvl'}]
228 },
229 'encode_map' =>
230 {
231 'pos' => { 'noun' => { 'prontype' => { '' => { 'poss' => { 'yes' => 'NN_S_PP',
232 '@' => { 'nountype' => { 'prop' => 'NNP',
233 '@' => { 'definite' => { 'cons' => 'NNT',
234 '@' => { 'other/nountype' => { 'title' => 'TTL',
235 '@' => 'NN' }}}}}}}},
236 'neg' => 'PRP-IMP',
237 '@' => 'PRP' }},
238 'adj' => { 'prontype' => { 'art' => 'DEF',
239 'tot' => 'DEF@DT',
240 'dem' => 'PRP-DEM',
241 'int' => 'QW',
242 'rel' => 'REL-SUBCONJ',
243 '' => { 'definite' => { 'cons' => 'JJT',
244 '@' => 'JJ' }},
245 '@' => { 'definite' => { 'cons' => 'DTT',
246 '@' => 'DT' }}}},
247 'num' => { 'definite' => { 'cons' => 'CDT',
248 '@' => { 'numform' => { 'digit' => 'NCD',
249 '@' => 'CD' }}}},
250 # There are two ways of tagging participles:
251 # BN (or BN_S_PP or BNT) part of speech ... we decode it as 'adj|verb'.
252 # VB part of speech, BEINONI feature ... we decode it as 'verb'.
253 'adj|verb' => { 'poss' => { 'yes' => 'BN_S_PP',
254 '@' => { 'definite' => { 'cons' => 'BNT',
255 '@' => 'BN' }}}},
256 'verb' => { 'verbtype' => { 'cop' => { 'verbform' => { 'inf' => 'COP-TOINFINITIVE',
257 '@' => 'COP' }},
258 'mod' => 'MD',
259 '@' => { 'verbform' => { 'inf' => { 'other/infinitive' => { 'to' => 'VB-TOINFINITIVE',
260 '@' => 'VB-BAREINFINITIVE' }},
261 '@' => 'VB' }}}},
262 'adv' => { 'advtype' => { 'ex' => 'EX',
263 '@' => { 'other/advtype' => { 'prefix' => 'ADVERB',
264 '@' => 'RB' }}}},
265 'conj' => { 'conjtype' => { 'coor' => 'CC-COORD',
266 'sub' => { 'advtype' => { 'tim' => 'TEMP-SUBCONJ',
267 '@' => 'CC-SUB' }},
268 '@' => { 'prontype' => { 'rel' => 'CC-REL',
269 '@' => 'CC' }}}},
270 'adp|conj' => 'IN',
271 'adp' => 'PREPOSITION',
272 'part' => { 'poss' => { 'yes' => 'POS',
273 '@' => { 'case' => { 'nom' => 'S_ANP',
274 '@' => { 'prontype' => { 'prs' => 'S_PRN',
275 '@' => { 'other/parttype' => { 'prefix' => 'P',
276 '@' => 'AT' }}}}}}}},
277 'int' => 'INTJ',
278 'punc' => 'PUNC',
279 '@' => { 'other/unknown' => { 'miss' => '!!MISS!!',
280 'some' => '!!SOME_!!',
281 'zvl' => '!!ZVL!!',
282 '@' => '!!UNK!!' }}}
283 }
284 );
285 # PRONOUN TYPE ####################
286 # Personal pronouns (PRP PRP PERS):
287 # אֲנִי aní = já
288 # אֲנַחְנוּ anáxnu = my (hovorově)
289 # אָנוּ ánu = my (spisovně)
290 # אַתָּה atá = ty (mužský rod)
291 # אַתְּ át = ty (ženský rod)
292 # אֲתֶּם atém = vy (mužský rod)
293 # אַתֶּן atén = vy (ženský rod)
294 # הוּא hu = on
295 # הִיא hi = ona
296 # הֵם hem = oni
297 # הֵן hen = ony
298 # Demonstrative pronouns (PRP PRP DEM):
299 # זֶה ze = tento
300 # זוֹ zó = tato
301 # Interrogative pronouns:
302 # מָה má = co, který, která
303 # מִי mí = kdo
304 # The undocumented "IMP" feature seems to mean "indefinite, negative or total pronoun".
305 # כולם \ כֻּלָּם kulám = all PRP PRP M|P|3|IMP
306 # כלשהו klšhú (כָּלְשֶׁהוּ) káləšhú = some PRP PRP M|S|3|IMP
307 # כלשהי klšhí (כָּלְשֶׁהִי) káləšhí = some PRP PRP F|S|IMP
308 # כלשהם klšhm (כָּלְשֶׁהֵם) káləšhem = any PRP PRP M|P|IMP
309 # כלשהן klšhn (כָּלְשֶׁהֵן) káləšhen = any PRP PRP F|P|IMP
310 # כְּלוּם kəlum = anything PRP PRP-IMP _
311 # Used with a negative word, so the combination means "nothing".
312 $atoms{prontype} = $self->create_atom
313 (
314 'surfeature' => 'prontype',
315 'decode_map' =>
316 {
317 'PERS' => ['prontype' => 'prs'],
318 'DEM' => ['prontype' => 'dem'],
319 # We would want to set prontype => 'ind|neg|tot' here but we cannot because we have to preserve the weird distinction of
320 # PRP PRP-IMP _
321 # PRP PRP F|P|IMP
322 'IMP' => ['prontype' => 'ind|tot']
323 },
324 'encode_map' =>
325 {
326 'prontype' => { 'prs' => 'PERS',
327 'dem' => 'DEM',
328 'ind' => 'IMP',
329 'neg' => 'IMP',
330 'tot' => 'IMP' }
331 }
332 );
333 # UNKNOWN WORDS ####################
334 $atoms{unknown} = $self->create_atom
335 (
336 'surfeature' => 'unknown',
337 'decode_map' =>
338 {
339 '!!MISS!!' => ['other' => {'unknown' => 'miss'}],
340 '!!UNK!!' => ['other' => {'unknown' => 'unk'}]
341 },
342 'encode_map' =>
343 {
344 'other/unknown' => { 'miss' => '!!MISS!!',
345 '@' => '!!UNK!!' }
346 }
347 );
348 # GENDER ####################
349 $atoms{gender} = $self->create_atom
350 (
351 'surfeature' => 'gender',
352 'decode_map' =>
353 {
354 # used usually with nouns. pronouns, numerals, verbs and adjectives
355 'M' => ['gender' => 'masc'],
356 'F' => ['gender' => 'fem'],
357 },
358 'encode_map' =>
359 {
360 'gender' => { 'masc' => 'M',
361 'fem' => 'F' }
362 }
363 );
364 # POSSESSOR'S GENDER ####################
365 $atoms{possgender} = $self->create_atom
366 (
367 'surfeature' => 'possgender',
368 'decode_map' =>
369 {
370 # used with NN and BN
371 'suf_M' => ['possgender' => 'masc'],
372 'suf_F' => ['possgender' => 'fem'],
373 'suf_MF' => ['possgender' => 'masc|fem']
374 },
375 'encode_map' =>
376 {
377 'possgender' => { 'masc|fem' => 'suf_MF',
378 'masc' => 'suf_M',
379 'fem' => 'suf_F' }
380 }
381 );
382 # NUMBER ####################
383 $atoms{number} = $self->create_atom
384 (
385 'surfeature' => 'number',
386 'decode_map' =>
387 {
388 # used usually with nouns. pronouns, numerals, verbs and adjectives
389 'S' => ['number' => 'sing'],
390 'D' => ['number' => 'dual'],
391 'DP'=> ['number' => 'dual|plur'], # pseudo-dual, that is dual used as plural
392 'P' => ['number' => 'plur'],
393 },
394 'encode_map' =>
395 {
396 'number' => { 'sing' => 'S',
397 'dual|plur' => 'DP',
398 'dual' => 'D',
399 'plur' => 'P' }
400 }
401 );
402 # POSSESSOR'S NUMBER ####################
403 $atoms{possnumber} = $self->create_atom
404 (
405 'surfeature' => 'possnumber',
406 'decode_map' =>
407 {
408 # used with NN and BN
409 'suf_S' => ['possnumber' => 'sing'],
410 'suf_P' => ['possnumber' => 'plur']
411 },
412 'encode_map' =>
413 {
414 'possnumber' => { 'sing' => 'suf_S',
415 'plur' => 'suf_P' }
416 }
417 );
418 # PERSON ####################
419 # The "A" feature:
420 # Used with BN, BNT, MD, VB (i.e. verb forms).
421 # For MD and VB, it always coincides with BEINONI.
422 # MD and VB BEINONI without A exist but they are very rare.
423 # COP BEINONI is always without A.
424 # It seems to replace the person feature, meaning person=all. (COP always has person.)
425 $atoms{person} = $self->create_atom
426 (
427 'surfeature' => 'person',
428 'decode_map' =>
429 {
430 # used with VB, COP, MD, BN; NN, PRP, S_PRP, S_ANP
431 '1' => ['person' => '1'],
432 '2' => ['person' => '2'],
433 '3' => ['person' => '3'],
434 'A' => [],
435 },
436 'encode_map' =>
437 {
438 'person' => { '1' => '1',
439 '2' => '2',
440 '3' => '3',
441 '' => 'A' }
442 }
443 );
444 # POSSESSOR'S PERSON ####################
445 $atoms{possperson} = $self->create_atom
446 (
447 'surfeature' => 'possperson',
448 'decode_map' =>
449 {
450 # used with NN and BN
451 'suf_1' => ['possperson' => '1'],
452 'suf_2' => ['possperson' => '2'],
453 'suf_3' => ['possperson' => '3']
454 },
455 'encode_map' =>
456 {
457 'possperson' => { '1' => 'suf_1',
458 '2' => 'suf_2',
459 '3' => 'suf_3' }
460 }
461 );
462 # VERB FORM ####################
463 $atoms{verbform} = $self->create_atom
464 (
465 'surfeature' => 'verbform',
466 'decode_map' =>
467 {
468 # used with COP and VB
469 'PAST' => ['tense' => 'past'],
470 'FUTURE' => ['tense' => 'fut'],
471 'IMPERATIVE' => ['mood' => 'imp'],
472 'BEINONI' => ['verbform' => 'part']
473 },
474 'encode_map' =>
475 {
476 'verbform' => { 'part' => 'BEINONI',
477 '@' => { 'mood' => { 'imp' => 'IMPERATIVE',
478 '@' => { 'tense' => { 'past' => 'PAST',
479 'fut' => 'FUTURE' }}}}}
480 }
481 );
482 # POLARITY ####################
483 $atoms{polarity} = $self->create_simple_atom
484 (
485 'intfeature' => 'polarity',
486 'simple_decode_map' =>
487 {
488 # used with COP
489 'POSITIVE' => 'pos',
490 'NEGATIVE' => 'neg'
491 }
492 );
493 # BINYANIM ####################
494 # used with VB, BN and BNT
495 # binyan = building, structure
496 # This seems to be a traditional part of Hebrew morphology. See e.g. page 1347 of:
497 # http://books.google.cz/books?id=l7UWMZq7FGIC&pg=PA1350&lpg=PA1350&dq=HIFIL+HITPAEL+HUFAL+NIFAL+PAAL+PIEL+PUAL+HIFIL&source=bl&ots=bnVti7b3wi&sig=8O9q5x0DA1DqYiH3g8yVY8r9qgM&hl=cs&sa=X&ei=pf1wVLeADcLOygON7YHoAw&ved=0CCkQ6AEwAQ#v=onepage&q=HIFIL%20HITPAEL%20HUFAL%20NIFAL%20PAAL%20PIEL%20PUAL%20HIFIL&f=false
498 # or
499 # http://tzion.org/devarim/The%20Seven%20Binyanim.pdf
500 $atoms{binyan} = $self->create_atom
501 (
502 'surfeature' => 'binyan',
503 'decode_map' =>
504 {
505 # PAAL CaCaC katav = wrote (basic/simple)
506 'PAAL' => ['voice' => 'act'],
507 # NIFAL niCCaC niktav = was written (basic/simple-passive)
508 'NIFAL' => ['voice' => 'pass'],
509 # PIEL CiCeC kitev = inscribed/engraved (intensive)
510 'PIEL' => ['voice' => 'int'],
511 # PUAL CuCaC kutav = was inscribed/engraved (intensive-passive) (theoretical, to illustrate the binyanim; not used with this root)
512 'PUAL' => ['voice' => 'int|pass'],
513 # HIFIL hiCCiC hiktiv = dictated (causative)
514 'HIFIL' => ['voice' => 'cau'],
515 # HUFAL huCCaC huktav = was dictated (causative-passive)
516 'HUFAL' => ['voice' => 'cau|pass'],
517 # HITPAEL hitCaCeC hitkatev = corresponded (reflexive/cooperative aspect ... both active and passive)
518 'HITPAEL' => ['voice' => 'mid']
519 },
520 'encode_map' =>
521 {
522 'voice' => { 'int|pass' => 'PUAL',
523 'cau|pass' => 'HUFAL',
524 'pass' => 'NIFAL',
525 'mid' => 'HITPAEL',
526 'act' => 'PAAL',
527 'cau' => 'HIFIL',
528 'int' => 'PIEL' }
529 }
530 );
531 # MERGED ATOM TO DECODE ANY FEATURE VALUE ####################
532 my @fatoms = map {$atoms{$_}} @{$self->features_all()};
533 $atoms{feature} = $self->create_merged_atom
534 (
535 'surfeature' => 'feature',
536 'atoms' => \@fatoms
537 );
538 return \%atoms;
539 }
540  
541  
542  
543 #------------------------------------------------------------------------------
544 # Creates the list of all surface CoNLL features that can appear in the FEATS
545 # column. This list will be used in decode().
546 #------------------------------------------------------------------------------
547 sub _create_features_all
548 {
549 my $self = shift;
550 my @features = ('gender', 'number', 'person', 'verbform', 'polarity', 'binyan', 'possgender', 'possnumber', 'possperson', 'prontype', 'unknown');
551 return \@features;
552 }
553  
554  
555  
556 #------------------------------------------------------------------------------
557 # Creates the list of surface CoNLL features that can appear in the FEATS
558 # column with particular parts of speech. This list will be used in encode().
559 #------------------------------------------------------------------------------
560 sub _create_features_pos
561 {
562 my $self = shift;
563 my %features =
564 (
565 '!!MISS!!' => ['unknown'],
566 '!!UNK!!' => ['unknown'],
567 'BN' => ['gender', 'number', 'person', 'binyan', 'possgender', 'possnumber', 'possperson'],
568 'BNT' => ['gender', 'number', 'person', 'binyan'],
569 'CD' => ['gender', 'number'],
570 'CDT' => ['gender', 'number'],
571 'COP' => ['gender', 'number', 'person', 'verbform', 'polarity'],
572 'COP-TOINFINITIVE' => ['polarity'],
573 'JJ' => ['gender', 'number'],
574 'JJT' => ['gender', 'number'],
575 'MD' => ['gender', 'number', 'person', 'verbform'],
576 'NN' => ['gender', 'number', 'possgender', 'possnumber', 'possperson'],
577 'NNP' => ['gender', 'number'],
578 'NNT' => ['gender', 'number'],
579 'PRP' => ['gender', 'number', 'person', 'prontype'],
580 'PRPIMP' => ['gender', 'number', 'prontype'],
581 'S_ANP' => ['gender', 'number', 'person'],
582 'S_PRN' => ['gender', 'number', 'person'],
583 'TTL' => ['gender', 'number'],
584 'VB' => ['gender', 'number', 'person', 'verbform', 'binyan'],
585 'VB-TOINFINITIVE' => ['binyan']
586 );
587 return \%features;
588 }
589  
590  
591  
592 #------------------------------------------------------------------------------
593 # Decodes a physical tag (string) and returns the corresponding feature
594 # structure.
595 #------------------------------------------------------------------------------
596 sub decode
597 {
598 my $self = shift;
599 my $tag = shift;
600 my $fs = Lingua::Interset::FeatureStructure->new();
601 $fs->set_tagset('he::conll');
602 my $atoms = $self->atoms();
603 # three components: part-of-speech tag, subpart of speech, features
604 # example: NN\tNN\tM|S
605 my ($pos, $subpos, $features) = split(/\s+/, $tag);
606 # The underscore character is used if there are no features.
607 $features = '' if($features eq '_');
608 my @features = split(/\|/, $features);
609 $atoms->{pos}->decode_and_merge_hard($subpos, $fs);
610 foreach my $feature (@features)
611 {
612 $atoms->{feature}->decode_and_merge_hard($feature, $fs);
613 }
614 # Default feature values. Used to improve collaboration with other drivers.
615 # ... nothing yet ...
616 return $fs;
617 }
618  
619  
620  
621 #------------------------------------------------------------------------------
622 # Takes feature structure and returns the corresponding physical tag (string).
623 #------------------------------------------------------------------------------
624 sub encode
625 {
626 my $self = shift;
627 my $fs = shift; # Lingua::Interset::FeatureStructure
628 my $atoms = $self->atoms();
629 my $pos = $atoms->{pos}->encode($fs);
630 my $subpos = $pos;
631 $pos =~ s/(_S_PP|-BAREINFINITIVE|-COORD|-DEM|-IMP|-REL|-SUB|-SUBCONJ|-TOINFINITIVE)$//;
632 my $fpos = $pos;
633 if($subpos =~ m/(PRP-DEM|PRP-IMP|INFINITIVE)/)
634 {
635 $fpos = $subpos;
636 }
637 elsif($fs->is_noun() && $fs->prontype() =~ m/ind|neg|tot/)
638 {
639 $fpos = 'PRPIMP';
640 }
641 my $feature_names = $self->get_feature_names($fpos);
642 my $value_only = 1;
643 my $tag = $self->encode_conll($fs, $pos, $subpos, $feature_names, $value_only);
644 return $tag;
645 }
646  
647  
648  
649 #------------------------------------------------------------------------------
650 # Returns reference to list of known tags.
651 # Tags were collected from the corpus and cleaned (canonical ordering of
652 # features).
653 # 370 tags after cleaning.
654 ###!!! TODO: Some of the original tags contained two values of gender (M|F) if
655 ###!!! the word did not distinguish gender. We currently cannot detect it
656 ###!!! because we process every feature independently but we should. For
657 ###!!! example, the first-person pronouns (and S_PRN) in Hebrew are genderless.
658 #------------------------------------------------------------------------------
659 sub list
660 {
661 my $self = shift;
662 my $list = <<end_of_list
663 !!MISS!! !!MISS!! !!MISS!!
664 !!SOME_!! !!SOME_!! _
665 !!UNK!! !!UNK!! !!UNK!!
666 !!ZVL!! !!ZVL!! _
667 ADVERB ADVERB _
668 AT AT _
669 BN BN F|P|A
670 BN BN F|P|A|HIFIL
671 BN BN F|P|A|HITPAEL
672 BN BN F|P|A|HUFAL
673 BN BN F|P|A|NIFAL
674 BN BN F|P|A|PAAL
675 BN BN F|P|A|PIEL
676 BN BN F|P|A|PUAL
677 BN BN F|S|3
678 BN BN F|S|A
679 BN BN F|S|A|HIFIL
680 BN BN F|S|A|HITPAEL
681 BN BN F|S|A|HUFAL
682 BN BN F|S|A|NIFAL
683 BN BN F|S|A|PAAL
684 BN BN F|S|A|PIEL
685 BN BN F|S|A|PUAL
686 BN BN M|P|1
687 BN BN M|P|3|HIFIL
688 BN BN M|P|A
689 BN BN M|P|A|HIFIL
690 BN BN M|P|A|HITPAEL
691 BN BN M|P|A|HUFAL
692 BN BN M|P|A|NIFAL
693 BN BN M|P|A|PAAL
694 BN BN M|P|A|PIEL
695 BN BN M|P|A|PUAL
696 BN BN M|S|A
697 BN BN M|S|A|HIFIL
698 BN BN M|S|A|HITPAEL
699 BN BN M|S|A|HUFAL
700 BN BN M|S|A|NIFAL
701 BN BN M|S|A|PAAL
702 BN BN M|S|A|PIEL
703 BN BN M|S|A|PUAL
704 BN BN_S_PP M|P|A|PAAL|suf_F|suf_P|suf_3
705 BN BN_S_PP M|P|A|PAAL|suf_F|suf_S|suf_3
706 BN BN_S_PP M|P|A|PAAL|suf_M|suf_S|suf_3
707 BN BN_S_PP M|S|A|HIFIL|suf_M|suf_S|suf_3
708 BN BN_S_PP M|S|A|PAAL|suf_F|suf_P|suf_3
709 BN BN_S_PP M|S|A|PAAL|suf_M|suf_P|suf_3
710 BN BN_S_PP M|S|A|PIEL|suf_M|suf_S|suf_3
711 BNT BNT F|P|A|HIFIL
712 BNT BNT F|P|A|HITPAEL
713 BNT BNT F|S|A|HIFIL
714 BNT BNT F|S|A|PAAL
715 BNT BNT M|P|A
716 BNT BNT M|P|A|HIFIL
717 BNT BNT M|P|A|HUFAL
718 BNT BNT M|P|A|NIFAL
719 BNT BNT M|P|A|PAAL
720 BNT BNT M|P|A|PIEL
721 BNT BNT M|S|A
722 BNT BNT M|S|A|HIFIL
723 BNT BNT M|S|A|PAAL
724 BNT BNT M|S|A|PIEL
725 BNT BNT M|S|A|PUAL
726 CC CC _
727 CC CC-COORD _
728 CC CC-REL _
729 CC CC-SUB _
730 CD CD F|D
731 CD CD F|P
732 CD CD F|S
733 CD CD M|D
734 CD CD M|P
735 CD CD M|S
736 CD CD _
737 CDT CDT F|D
738 CDT CDT F|P
739 CDT CDT F|S
740 CDT CDT M|D
741 CDT CDT M|P
742 CDT CDT M|S
743 COP COP F|P|3|BEINONI|NEGATIVE
744 COP COP F|P|3|FUTURE|POSITIVE
745 COP COP F|S|2|PAST|POSITIVE
746 COP COP F|S|3|BEINONI|NEGATIVE
747 COP COP F|S|3|BEINONI|POSITIVE
748 COP COP F|S|3|FUTURE|POSITIVE
749 COP COP F|S|3|PAST|POSITIVE
750 COP COP M|P|1|BEINONI|NEGATIVE
751 COP COP M|P|1|BEINONI|POSITIVE
752 COP COP M|P|1|FUTURE|POSITIVE
753 COP COP M|P|2|BEINONI|NEGATIVE
754 COP COP M|P|2|IMPERATIVE|POSITIVE
755 COP COP M|P|3|BEINONI|NEGATIVE
756 COP COP M|P|3|BEINONI|POSITIVE
757 COP COP M|P|3|FUTURE|POSITIVE
758 COP COP M|S|1|BEINONI|NEGATIVE
759 COP COP M|S|1|PAST|POSITIVE
760 COP COP M|S|2|BEINONI|NEGATIVE
761 COP COP M|S|2|IMPERATIVE|POSITIVE
762 COP COP M|S|3|BEINONI|NEGATIVE
763 COP COP M|S|3|BEINONI|POSITIVE
764 COP COP M|S|3|FUTURE|POSITIVE
765 COP COP M|S|3|PAST|POSITIVE
766 COP COP-TOINFINITIVE POSITIVE
767 DEF DEF _
768 DEF\@DT DEF\@DT _
769 DT DT _
770 DTT DTT _
771 EX EX _
772 IN IN _
773 INTJ INTJ _
774 JJ JJ F|P
775 JJ JJ F|S
776 JJ JJ M|P
777 JJ JJ M|S
778 JJ JJ _
779 JJT JJT F|P
780 JJT JJT F|S
781 JJT JJT M|P
782 JJT JJT M|S
783 MD MD A
784 MD MD F|P|A
785 MD MD F|P|A|BEINONI
786 MD MD F|S|3|FUTURE
787 MD MD F|S|A
788 MD MD F|S|A|BEINONI
789 MD MD M|P|1|FUTURE
790 MD MD M|P|1|PAST
791 MD MD M|P|3|FUTURE
792 MD MD M|P|A
793 MD MD M|P|A|BEINONI
794 MD MD M|S|2|FUTURE
795 MD MD M|S|A
796 MD MD M|S|A|BEINONI
797 MD MD M|S|A|PAST
798 NCD NCD _
799 NN NN F|D
800 NN NN F|DP
801 NN NN F|P
802 NN NN F|S
803 NN NN M
804 NN NN M|D
805 NN NN M|DP
806 NN NN M|P
807 NN NN M|S
808 NN NN S
809 NN NN _
810 NN NN_S_PP F|P|suf_F|suf_P|suf_3
811 NN NN_S_PP F|P|suf_F|suf_S|suf_2
812 NN NN_S_PP F|P|suf_F|suf_S|suf_3
813 NN NN_S_PP F|P|suf_MF|suf_P|suf_1
814 NN NN_S_PP F|P|suf_MF|suf_S|suf_1
815 NN NN_S_PP F|P|suf_M|suf_P|suf_2
816 NN NN_S_PP F|P|suf_M|suf_P|suf_3
817 NN NN_S_PP F|P|suf_M|suf_S|suf_3
818 NN NN_S_PP F|S|suf_F|suf_P|suf_3
819 NN NN_S_PP F|S|suf_F|suf_S|suf_2
820 NN NN_S_PP F|S|suf_F|suf_S|suf_3
821 NN NN_S_PP F|S|suf_MF|suf_P|suf_1
822 NN NN_S_PP F|S|suf_MF|suf_S|suf_1
823 NN NN_S_PP F|S|suf_M|suf_P|suf_2
824 NN NN_S_PP F|S|suf_M|suf_P|suf_3
825 NN NN_S_PP F|S|suf_M|suf_S|suf_3
826 NN NN_S_PP M|P|suf_F|suf_P|suf_3
827 NN NN_S_PP M|P|suf_F|suf_S|suf_2
828 NN NN_S_PP M|P|suf_F|suf_S|suf_3
829 NN NN_S_PP M|P|suf_MF|suf_P|suf_1
830 NN NN_S_PP M|P|suf_MF|suf_S|suf_1
831 NN NN_S_PP M|P|suf_M|suf_P|suf_2
832 NN NN_S_PP M|P|suf_M|suf_P|suf_3
833 NN NN_S_PP M|P|suf_M|suf_S|suf_3
834 NN NN_S_PP M|S|suf_F|suf_P|suf_3
835 NN NN_S_PP M|S|suf_F|suf_S|suf_2
836 NN NN_S_PP M|S|suf_F|suf_S|suf_3
837 NN NN_S_PP M|S|suf_MF|suf_P|suf_1
838 NN NN_S_PP M|S|suf_MF|suf_S|suf_1
839 NN NN_S_PP M|S|suf_M|suf_P|suf_2
840 NN NN_S_PP M|S|suf_M|suf_P|suf_3
841 NN NN_S_PP M|S|suf_M|suf_S|suf_3
842 NNP NNP F|S
843 NNP NNP M|S
844 NNP NNP _
845 NNT NNT F|P
846 NNT NNT F|S
847 NNT NNT M|P
848 NNT NNT M|S
849 P P _
850 POS POS _
851 PREPOSITION PREPOSITION _
852 PRP PRP F|P|1|PERS
853 PRP PRP F|P|3|DEM
854 PRP PRP F|P|3|PERS
855 PRP PRP F|P|IMP
856 PRP PRP F|S|1|PERS
857 PRP PRP F|S|3|DEM
858 PRP PRP F|S|3|PERS
859 PRP PRP F|S|IMP
860 PRP PRP M|P|1|PERS
861 PRP PRP M|P|2|PERS
862 PRP PRP M|P|3|DEM
863 PRP PRP M|P|3|PERS
864 PRP PRP M|P|IMP
865 PRP PRP M|S|1|PERS
866 PRP PRP M|S|2|PERS
867 PRP PRP M|S|3|DEM
868 PRP PRP M|S|3|PERS
869 PRP PRP M|S|IMP
870 PRP PRP-DEM _
871 PRP PRP-IMP _
872 PUNC PUNC _
873 QW QW _
874 RB RB _
875 REL REL-SUBCONJ _
876 S_ANP S_ANP F|P|3
877 S_ANP S_ANP F|S|3
878 S_ANP S_ANP M|P|3
879 S_ANP S_ANP M|S|2
880 S_ANP S_ANP M|S|3
881 S_PRN S_PRN F|P|1
882 S_PRN S_PRN F|P|3
883 S_PRN S_PRN F|S|1
884 S_PRN S_PRN F|S|2
885 S_PRN S_PRN F|S|3
886 S_PRN S_PRN M|P|1
887 S_PRN S_PRN M|P|2
888 S_PRN S_PRN M|P|3
889 S_PRN S_PRN M|S|1
890 S_PRN S_PRN M|S|2
891 S_PRN S_PRN M|S|3
892 TEMP TEMP-SUBCONJ _
893 TTL TTL M|S
894 TTL TTL S
895 VB VB F|P|2|IMPERATIVE
896 VB VB F|P|2|IMPERATIVE|PAAL
897 VB VB F|P|3|FUTURE|PAAL
898 VB VB F|P|3|FUTURE|PIEL
899 VB VB F|P|3|PAST
900 VB VB F|P|A|BEINONI|HIFIL
901 VB VB F|P|A|BEINONI|HITPAEL
902 VB VB F|P|A|BEINONI|HUFAL
903 VB VB F|P|A|BEINONI|NIFAL
904 VB VB F|P|A|BEINONI|PAAL
905 VB VB F|P|A|BEINONI|PIEL
906 VB VB F|P|A|BEINONI|PUAL
907 VB VB F|S|2|FUTURE|HUFAL
908 VB VB F|S|2|FUTURE|PAAL
909 VB VB F|S|2|IMPERATIVE|PAAL
910 VB VB F|S|2|IMPERATIVE|PIEL
911 VB VB F|S|2|PAST
912 VB VB F|S|2|PAST|HIFIL
913 VB VB F|S|2|PAST|HITPAEL
914 VB VB F|S|2|PAST|PAAL
915 VB VB F|S|2|PAST|PIEL
916 VB VB F|S|3|FUTURE|HIFIL
917 VB VB F|S|3|FUTURE|HITPAEL
918 VB VB F|S|3|FUTURE|HUFAL
919 VB VB F|S|3|FUTURE|NIFAL
920 VB VB F|S|3|FUTURE|PAAL
921 VB VB F|S|3|FUTURE|PIEL
922 VB VB F|S|3|FUTURE|PUAL
923 VB VB F|S|3|PAST
924 VB VB F|S|3|PAST|HIFIL
925 VB VB F|S|3|PAST|HITPAEL
926 VB VB F|S|3|PAST|HUFAL
927 VB VB F|S|3|PAST|NIFAL
928 VB VB F|S|3|PAST|PAAL
929 VB VB F|S|3|PAST|PIEL
930 VB VB F|S|3|PAST|PUAL
931 VB VB F|S|A|BEINONI
932 VB VB F|S|A|BEINONI|HIFIL
933 VB VB F|S|A|BEINONI|HITPAEL
934 VB VB F|S|A|BEINONI|HUFAL
935 VB VB F|S|A|BEINONI|NIFAL
936 VB VB F|S|A|BEINONI|PAAL
937 VB VB F|S|A|BEINONI|PIEL
938 VB VB F|S|A|BEINONI|PUAL
939 VB VB M|P|2|PAST|PAAL
940 VB VB M|P|2|PAST|PIEL
941 VB VB M|P|3|BEINONI|HIFIL
942 VB VB M|P|3|FUTURE|PIEL
943 VB VB M|P|3|PAST
944 VB VB M|P|A|BEINONI|HIFIL
945 VB VB M|P|A|BEINONI|HITPAEL
946 VB VB M|P|A|BEINONI|HUFAL
947 VB VB M|P|A|BEINONI|NIFAL
948 VB VB M|P|A|BEINONI|PAAL
949 VB VB M|P|A|BEINONI|PIEL
950 VB VB M|P|A|BEINONI|PUAL
951 VB VB M|S|1|PAST
952 VB VB M|S|2|IMPERATIVE
953 VB VB M|S|2|IMPERATIVE|HIFIL
954 VB VB M|S|2|IMPERATIVE|HITPAEL
955 VB VB M|S|2|IMPERATIVE|PAAL
956 VB VB M|S|2|IMPERATIVE|PIEL
957 VB VB M|S|3|FUTURE|HIFIL
958 VB VB M|S|3|FUTURE|HITPAEL
959 VB VB M|S|3|FUTURE|HUFAL
960 VB VB M|S|3|FUTURE|NIFAL
961 VB VB M|S|3|FUTURE|PAAL
962 VB VB M|S|3|FUTURE|PIEL
963 VB VB M|S|3|FUTURE|PUAL
964 VB VB M|S|3|PAST
965 VB VB M|S|3|PAST|HIFIL
966 VB VB M|S|3|PAST|HITPAEL
967 VB VB M|S|3|PAST|HUFAL
968 VB VB M|S|3|PAST|NIFAL
969 VB VB M|S|3|PAST|PAAL
970 VB VB M|S|3|PAST|PIEL
971 VB VB M|S|3|PAST|PUAL
972 VB VB M|S|A|BEINONI|HIFIL
973 VB VB M|S|A|BEINONI|HITPAEL
974 VB VB M|S|A|BEINONI|HUFAL
975 VB VB M|S|A|BEINONI|NIFAL
976 VB VB M|S|A|BEINONI|PAAL
977 VB VB M|S|A|BEINONI|PIEL
978 VB VB M|S|A|BEINONI|PUAL
979 VB VB P|1|FUTURE|HIFIL
980 VB VB P|1|FUTURE|HITPAEL
981 VB VB P|1|FUTURE|HUFAL
982 VB VB P|1|FUTURE|NIFAL
983 VB VB P|1|FUTURE|PAAL
984 VB VB P|1|FUTURE|PIEL
985 VB VB P|1|PAST
986 VB VB P|1|PAST|HIFIL
987 VB VB P|1|PAST|HITPAEL
988 VB VB P|1|PAST|NIFAL
989 VB VB P|1|PAST|PAAL
990 VB VB P|1|PAST|PIEL
991 VB VB P|1|PAST|PUAL
992 VB VB P|2|FUTURE|HIFIL
993 VB VB P|2|FUTURE|PAAL
994 VB VB P|2|IMPERATIVE
995 VB VB P|2|IMPERATIVE|NIFAL
996 VB VB P|2|IMPERATIVE|PAAL
997 VB VB P|3|FUTURE
998 VB VB P|3|FUTURE|HIFIL
999 VB VB P|3|FUTURE|HITPAEL
1000 VB VB P|3|FUTURE|HUFAL
1001 VB VB P|3|FUTURE|NIFAL
1002 VB VB P|3|FUTURE|PAAL
1003 VB VB P|3|FUTURE|PIEL
1004 VB VB P|3|FUTURE|PUAL
1005 VB VB P|3|PAST
1006 VB VB P|3|PAST|HIFIL
1007 VB VB P|3|PAST|HITPAEL
1008 VB VB P|3|PAST|HUFAL
1009 VB VB P|3|PAST|NIFAL
1010 VB VB P|3|PAST|PAAL
1011 VB VB P|3|PAST|PIEL
1012 VB VB P|3|PAST|PUAL
1013 VB VB S|1|FUTURE|HIFIL
1014 VB VB S|1|FUTURE|HITPAEL
1015 VB VB S|1|FUTURE|NIFAL
1016 VB VB S|1|FUTURE|PAAL
1017 VB VB S|1|FUTURE|PIEL
1018 VB VB S|1|FUTURE|PUAL
1019 VB VB S|1|PAST|HIFIL
1020 VB VB S|1|PAST|HITPAEL
1021 VB VB S|1|PAST|HUFAL
1022 VB VB S|1|PAST|NIFAL
1023 VB VB S|1|PAST|PAAL
1024 VB VB S|1|PAST|PIEL
1025 VB VB S|1|PAST|PUAL
1026 VB VB-BAREINFINITIVE _
1027 VB VB-TOINFINITIVE HIFIL
1028 VB VB-TOINFINITIVE HITPAEL
1029 VB VB-TOINFINITIVE NIFAL
1030 VB VB-TOINFINITIVE PAAL
1031 VB VB-TOINFINITIVE PIEL
1032 VB VB-TOINFINITIVE _
1033 end_of_list
1034 ;
1035 # Protect from editors that replace tabs by spaces.
1036 $list =~ s/ \s+/\t/sg;
1037 my @list = split(/\r?\n/, $list);
1038 return \@list;
1039 }
1040  
1041  
1042  
1043 1;
1044  
1045 __END__
1046  
1047 =pod
1048  
1049 =encoding UTF-8
1050  
1051 =head1 NAME
1052  
1053 Lingua::Interset::Tagset::HE::Conll - Driver for the Hebrew tagset.
1054  
1055 =head1 VERSION
1056  
1057 version 3.014
1058  
1059 =head1 SYNOPSIS
1060  
1061 use Lingua::Interset::Tagset::HE::Conll;
1062 my $driver = Lingua::Interset::Tagset::HE::Conll->new();
1063 my $fs = $driver->decode("NN\tNN\tM|S");
1064  
1065 or
1066  
1067 use Lingua::Interset qw(decode);
1068 my $fs = decode('he::conll', "NN\tNN\tM|S");
1069  
1070 =head1 DESCRIPTION
1071  
1072 Interset driver for the Hebrew tagset in CoNLL format.
1073 CoNLL tagsets in Interset are traditionally three values separated by tabs.
1074 The values come from the CoNLL columns CPOS, POS and FEAT.
1075  
1076 Tagset described in Yoav Goldberg: Automatic Syntactic Processing of Modern
1077 Hebrew Automatic Syntactic Processing of Modern Hebrew (2011), p. 32,
1078 L<http://www.cs.bgu.ac.il/~nlpproj/yoav-phd.pdf>
1079  
1080 TODO: try to use the official (but not as easy to process) resource:
1081 BGU Computational Linguistics Group. Hebrew morphological tagging guidelines.
1082 Technical report, Ben Gurion University of the Negev, 2008.
1083 L<http://www.cs.bgu.ac.il/~adlerm/tagging-guideline.pdf>
1084  
1085 =head1 SEE ALSO
1086  
1087 L<Lingua::Interset>,
1088 L<Lingua::Interset::Tagset>,
1089 L<Lingua::Interset::Tagset::Conll>,
1090 L<Lingua::Interset::FeatureStructure>
1091  
1092 =head1 AUTHOR
1093  
1094 Rudolf Rosa <rosa@ufal.mff.cuni.cz>
1095  
1096 =head1 AUTHOR
1097  
1098 Dan Zeman <zeman@ufal.mff.cuni.cz>
1099  
1100 =head1 COPYRIGHT AND LICENSE
1101  
1102 This software is copyright (c) 2019 by Univerzita Karlova (Charles University).
1103  
1104 This is free software; you can redistribute it and/or modify it under
1105 the same terms as the Perl 5 programming language system itself.
1106  
1107 =cut