| 1 | # ABSTRACT: Driver for the Swedish tagset of the Stockholm-Umeå Corpus. | ||
| 2 | # Copyright © 2015, 2017 Dan Zeman <zeman@ufal.mff.cuni.cz> | ||
| 3 | |||
| 4 | package Lingua::Interset::Tagset::SV::Suc; | ||
| 5 | use strict; | ||
| 6 | use warnings; | ||
| 7 | our $VERSION = '3.015'; | ||
| 8 | |||
| 9 | use utf8; | ||
| 10 | use open ':utf8'; | ||
| 11 | use namespace::autoclean; | ||
| 12 | use Moose; | ||
| 13 | extends 'Lingua::Interset::Tagset'; | ||
| 14 | |||
| 15 | |||
| 16 | |||
| 17 | has 'atoms' => ( isa => 'HashRef', is => 'ro', builder => '_create_atoms', lazy => 1 ); | ||
| 18 | has 'features_pos' => ( isa => 'HashRef', is => 'ro', builder => '_create_features_pos', lazy => 1 ); | ||
| 19 | |||
| 20 | |||
| 21 | |||
| 22 | #------------------------------------------------------------------------------ | ||
| 23 | # Returns the tagset id that should be set as the value of the 'tagset' feature | ||
| 24 | # during decoding. Every derived class must (re)define this method! The result | ||
| 25 | # should correspond to the last two parts in package name, lowercased. | ||
| 26 | # Specifically, it should be the ISO 639-2 language code, followed by '::' and | ||
| 27 | # a language-specific tagset id. Example: 'cs::multext'. | ||
| 28 | #------------------------------------------------------------------------------ | ||
| 29 | sub get_tagset_id | ||
| 30 | { | ||
| 31 | return 'sv::suc'; | ||
| 32 | } | ||
| 33 | |||
| 34 | |||
| 35 | |||
| 36 | #------------------------------------------------------------------------------ | ||
| 37 | # Creates atomic drivers for the surface features. | ||
| 38 | # http://spraakbanken.gu.se/parole/tags.phtml | ||
| 39 | #------------------------------------------------------------------------------ | ||
| 40 | sub _create_atoms | ||
| 41 | { | ||
| 42 | my $self = shift; | ||
| 43 | my %atoms; | ||
| 44 | # 1. PART OF SPEECH #################### | ||
| 45 | $atoms{pos} = $self->create_atom | ||
| 46 | ( | ||
| 47 | 'surfeature' => 'pos', | ||
| 48 | 'decode_map' => | ||
| 49 | { | ||
| 50 | # adverb / adverb | ||
| 51 | # examples: inte, också, så, bara, nu | ||
| 52 | 'AB' => ['pos' => 'adv'], | ||
| 53 | # determiner / determinerare | ||
| 54 | # examples: en, ett, den, det, alla, några, inga, de | ||
| 55 | 'DT' => ['pos' => 'adj', 'prontype' => 'prn'], | ||
| 56 | # interrogative/relative adverb / frågande/relativt adverb | ||
| 57 | # example: när, där, hur, som, då | ||
| 58 | 'HA' => ['pos' => 'adv', 'prontype' => 'int|rel'], | ||
| 59 | # interrogative/relative determiner / frågande/relativ determinerare | ||
| 60 | # examples: vilken, vilket, vilka | ||
| 61 | 'HD' => ['pos' => 'adj', 'prontype' => 'int|rel'], | ||
| 62 | # interrogative/relative pronoun / frågande/relativt pronomen | ||
| 63 | # examples: som, vilken, vem, vilket, vad, vilka | ||
| 64 | 'HP' => ['pos' => 'noun', 'prontype' => 'int|rel'], | ||
| 65 | # interrogative/relative possessive pronoun / frågande/relativt possesivt pronomen | ||
| 66 | # example: vars | ||
| 67 | 'HS' => ['pos' => 'adj', 'prontype' => 'int|rel', 'poss' => 'yes'], | ||
| 68 | # infinitive marker / infinitivmärke | ||
| 69 | # example: att | ||
| 70 | 'IE' => ['pos' => 'part', 'verbform' => 'inf'], ###!!! what is the current standard about infinitive markers? | ||
| 71 | # interjection / interjektion | ||
| 72 | # example: jo, ja, nej | ||
| 73 | 'IN' => ['pos' => 'int'], | ||
| 74 | # adjective / adjektiv | ||
| 75 | # examples: stor, annan, själv, sådan, viss | ||
| 76 | 'JJ' => ['pos' => 'adj'], | ||
| 77 | # coordinating conjunction / konjunktion | ||
| 78 | # examples: och, eller, som, än, men | ||
| 79 | 'KN' => ['pos' => 'conj', 'conjtype' => 'coor'], | ||
| 80 | # meaning separating punctuation / meningsskiljande interpunktion | ||
| 81 | # examples: . ? : ! ... | ||
| 82 | 'MAD' => ['pos' => 'punc', 'punctype' => 'peri|qest|excl|colo'], | ||
| 83 | # punctuation inside of sentence / interpunktion | ||
| 84 | # examples: , - : * ; | ||
| 85 | 'MID' => ['pos' => 'punc', 'punctype' => 'comm|dash|semi'], # or 'colo'; but we do not want a conflict with 'MAD' | ||
| 86 | # noun / substantiv | ||
| 87 | # examples: år, arbete, barn, sätt, äktenskap | ||
| 88 | 'NN' => ['pos' => 'noun', 'nountype' => 'com'], | ||
| 89 | # paired punctuation / interpunktion | ||
| 90 | # examples: ' ( ) | ||
| 91 | 'PAD' => ['pos' => 'punc', 'punctype' => 'quot|brck'], | ||
| 92 | # participle / particip | ||
| 93 | # examples: särskild, ökad, beredd, gift, oförändrad | ||
| 94 | 'PC' => ['pos' => 'verb', 'verbform' => 'part'], | ||
| 95 | # particle / partikel | ||
| 96 | # examples: ut, upp, in, till, med | ||
| 97 | ###!!! Joakim currently converts the particles to adpositions because these are the Germanic verb particles. | ||
| 98 | 'PL' => ['pos' => 'part'], | ||
| 99 | # proper name / egennamn | ||
| 100 | # example: F, N, Liechtenstein, Danmark, DK | ||
| 101 | 'PM' => ['pos' => 'noun', 'nountype' => 'prop'], | ||
| 102 | # pronoun / pronomen | ||
| 103 | # examples: han, den, vi, det, denne, de, dessa | ||
| 104 | 'PN' => ['pos' => 'noun', 'prontype' => 'prn'], | ||
| 105 | # preposition / preposition | ||
| 106 | # examples: i, av, på, för, till | ||
| 107 | 'PP' => ['pos' => 'adp', 'adpostype' => 'prep'], | ||
| 108 | # possessive pronoun / possesivt pronomen | ||
| 109 | # examples: min, din, sin, vår, er, mitt, ditt, sitt, vårt, ert, mina, dina, sina, våra | ||
| 110 | 'PS' => ['pos' => 'adj', 'prontype' => 'prs', 'poss' => 'yes'], | ||
| 111 | # cardinal numeral / grundtal | ||
| 112 | # examples: en, ett, två, tre, 1, 20, 2 | ||
| 113 | 'RG' => ['pos' => 'num', 'numtype' => 'card'], | ||
| 114 | # ordinal numeral / ordningstal | ||
| 115 | # examples: första, andra, tredje, fjärde, femte | ||
| 116 | 'RO' => ['pos' => 'adj', 'numtype' => 'ord'], | ||
| 117 | # subordinating conjunction / subjunktion | ||
| 118 | # examples: att, om, innan, eftersom, medan | ||
| 119 | 'SN' => ['pos' => 'conj', 'conjtype' => 'sub'], | ||
| 120 | # foreign word / utländskt ord | ||
| 121 | # examples: companionship, vice, versa, family, capita | ||
| 122 | 'UO' => ['foreign' => 'yes'], | ||
| 123 | # verb / verb | ||
| 124 | # examples: vara, få, ha, bli, kunna | ||
| 125 | 'VB' => ['pos' => 'verb'], | ||
| 126 | }, | ||
| 127 | 'encode_map' => | ||
| 128 | { | ||
| 129 | 'pos' => { 'noun' => { 'prontype' => { '' => { 'nountype' => { 'prop' => 'PM', | ||
| 130 | '@' => 'NN' }}, | ||
| 131 | 'int' => { 'poss' => { 'yes' => 'HS', | ||
| 132 | '@' => 'HP' }}, | ||
| 133 | '@' => { 'poss' => { 'yes' => 'PS', | ||
| 134 | '@' => 'PN' }}}}, | ||
| 135 | 'adj' => { 'prontype' => { '' => { 'verbform' => { 'part' => 'PC', | ||
| 136 | '@' => { 'numtype' => { 'ord' => 'RO', | ||
| 137 | '@' => 'JJ' }}}}, | ||
| 138 | 'int' => { 'poss' => { 'yes' => 'HS', | ||
| 139 | '@' => 'HD' }}, | ||
| 140 | '@' => { 'poss' => { 'yes' => 'PS', | ||
| 141 | '@' => 'DT' }}}}, | ||
| 142 | 'num' => { 'numtype' => { 'ord' => 'RO', | ||
| 143 | '@' => 'RG' }}, | ||
| 144 | 'verb' => { 'verbform' => { 'part' => 'PC', | ||
| 145 | '@' => 'VB' }}, | ||
| 146 | 'adv' => { 'prontype' => { 'int' => 'HA', | ||
| 147 | '@' => 'AB' }}, | ||
| 148 | 'adp' => 'PP', | ||
| 149 | 'conj' => { 'verbform' => { 'inf' => 'IE', | ||
| 150 | '@' => { 'conjtype' => { 'sub' => 'SN', | ||
| 151 | '@' => 'KN' }}}}, | ||
| 152 | 'part' => { 'verbform' => { 'inf' => 'IE', | ||
| 153 | '@' => 'PL' }}, | ||
| 154 | 'int' => 'IN', | ||
| 155 | 'punc' => { 'punctype' => { 'peri' => 'MAD', | ||
| 156 | 'qest' => 'MAD', | ||
| 157 | 'excl' => 'MAD', | ||
| 158 | 'colo' => 'MAD', # or MID | ||
| 159 | 'comm' => 'MID', | ||
| 160 | 'semi' => 'MID', | ||
| 161 | 'dash' => 'MID', | ||
| 162 | 'quot' => 'PAD', | ||
| 163 | 'brck' => 'PAD', | ||
| 164 | '@' => 'MID' }}, | ||
| 165 | '@' => 'UO' } | ||
| 166 | } | ||
| 167 | ); | ||
| 168 | # 2. DEGREE #################### | ||
| 169 | $atoms{degree} = $self->create_simple_atom | ||
| 170 | ( | ||
| 171 | 'intfeature' => 'degree', | ||
| 172 | 'simple_decode_map' => | ||
| 173 | { | ||
| 174 | 'POS' => 'pos', | ||
| 175 | 'KOM' => 'cmp', | ||
| 176 | 'SUV' => 'sup' | ||
| 177 | } | ||
| 178 | ); | ||
| 179 | # 3. GENDER #################### | ||
| 180 | $atoms{gender} = $self->create_simple_atom | ||
| 181 | ( | ||
| 182 | 'intfeature' => 'gender', | ||
| 183 | 'simple_decode_map' => | ||
| 184 | { | ||
| 185 | 'MAS' => 'masc', | ||
| 186 | 'UTR' => 'com', | ||
| 187 | 'NEU' => 'neut', | ||
| 188 | 'UTR/NEU' => '' | ||
| 189 | } | ||
| 190 | ); | ||
| 191 | # 4. NUMBER #################### | ||
| 192 | $atoms{number} = $self->create_simple_atom | ||
| 193 | ( | ||
| 194 | 'intfeature' => 'number', | ||
| 195 | 'simple_decode_map' => | ||
| 196 | { | ||
| 197 | 'SIN' => 'sing', | ||
| 198 | 'PLU' => 'plur', | ||
| 199 | 'SIN/PLU' => '' | ||
| 200 | } | ||
| 201 | ); | ||
| 202 | # 5. CASE #################### | ||
| 203 | $atoms{case} = $self->create_simple_atom | ||
| 204 | ( | ||
| 205 | 'intfeature' => 'case', | ||
| 206 | 'simple_decode_map' => | ||
| 207 | { | ||
| 208 | 'NOM' => 'nom', | ||
| 209 | 'GEN' => 'gen' | ||
| 210 | } | ||
| 211 | ); | ||
| 212 | # 6. SUBJECT / OBJECT FORM #################### | ||
| 213 | $atoms{subjobj} = $self->create_simple_atom | ||
| 214 | ( | ||
| 215 | 'intfeature' => 'case', | ||
| 216 | 'simple_decode_map' => | ||
| 217 | { | ||
| 218 | 'SUB' => 'nom', | ||
| 219 | 'OBJ' => 'acc', | ||
| 220 | 'SUB/OBJ' => '' | ||
| 221 | } | ||
| 222 | ); | ||
| 223 | # 7. DEFINITENESS #################### | ||
| 224 | $atoms{definite} = $self->create_simple_atom | ||
| 225 | ( | ||
| 226 | 'intfeature' => 'definite', | ||
| 227 | 'simple_decode_map' => | ||
| 228 | { | ||
| 229 | 'DEF' => 'def', | ||
| 230 | 'IND' => 'ind', | ||
| 231 | 'IND/DEF' => '' | ||
| 232 | } | ||
| 233 | ); | ||
| 234 | # 8. VERB FORM, MOOD, TENSE AND ASPECT #################### | ||
| 235 | $atoms{verbform} = $self->create_atom | ||
| 236 | ( | ||
| 237 | 'surfeature' => 'verbform', | ||
| 238 | 'decode_map' => | ||
| 239 | { | ||
| 240 | # infinitive / infinitiv | ||
| 241 | 'INF' => ['verbform' => 'inf'], | ||
| 242 | # perfect participle / particip perfekt | ||
| 243 | 'PRF' => ['verbform' => 'part', 'aspect' => 'perf', 'tense' => 'past'], | ||
| 244 | # present indicative or present subjunctive or present participle / presens eller particip presens | ||
| 245 | 'PRS' => ['tense' => 'pres'], | ||
| 246 | # past indicative or subjunctive / preteritum | ||
| 247 | 'PRT' => ['verbform' => 'fin', 'tense' => 'past'], | ||
| 248 | # imperative / imperativ | ||
| 249 | 'IMP' => ['verbform' => 'fin', 'mood' => 'imp'], | ||
| 250 | # subjunctive / konjunktiv | ||
| 251 | 'KON' => ['verbform' => 'fin', 'mood' => 'sub'], | ||
| 252 | # supine / supinum | ||
| 253 | 'SUP' => ['verbform' => 'sup'] | ||
| 254 | }, | ||
| 255 | 'encode_map' => | ||
| 256 | { | ||
| 257 | 'verbform' => { 'inf' => 'INF', | ||
| 258 | 'fin' => { 'mood' => { 'ind' => { 'tense' => { 'pres' => 'PRS', | ||
| 259 | 'past' => 'PRT' }}, | ||
| 260 | 'sub' => { 'tense' => { 'pres' => 'KON|PRS', | ||
| 261 | 'past' => 'KON|PRT' }}, | ||
| 262 | 'imp' => 'IMP', | ||
| 263 | '@' => { 'tense' => { 'pres' => 'PRS', | ||
| 264 | 'past' => 'PRT' }}}}, | ||
| 265 | 'sup' => 'SUP', | ||
| 266 | 'part' => { 'tense' => { 'pres' => 'PRS', | ||
| 267 | 'past' => 'PRF' }}, | ||
| 268 | '@' => { 'tense' => { 'pres' => 'PRS' }}} | ||
| 269 | } | ||
| 270 | ); | ||
| 271 | # 9. VOICE #################### | ||
| 272 | $atoms{voice} = $self->create_simple_atom | ||
| 273 | ( | ||
| 274 | 'intfeature' => 'voice', | ||
| 275 | 'simple_decode_map' => | ||
| 276 | { | ||
| 277 | # E.g. verb preteritum aktiv | ||
| 278 | # Example: hänvisade = referred | ||
| 279 | 'AKT' => 'act', | ||
| 280 | # E.g. verb preteritum s-form | ||
| 281 | # Example: tillfrågades = asked | ||
| 282 | ###!!! How did we come to conclude that "s-form" means passive? | ||
| 283 | ###!!! But Joakim also decodes it as passive. | ||
| 284 | 'SFO' => 'pass' | ||
| 285 | } | ||
| 286 | ); | ||
| 287 | # 10. FORM #################### | ||
| 288 | $atoms{form} = $self->create_atom | ||
| 289 | ( | ||
| 290 | 'surfeature' => 'form', | ||
| 291 | 'decode_map' => | ||
| 292 | { | ||
| 293 | # hyphenated prefix / sammansättningsform | ||
| 294 | 'SMS' => ['hyph' => 'yes'], | ||
| 295 | # abbreviation / förkortning | ||
| 296 | 'AN' => ['abbr' => 'yes'] | ||
| 297 | }, | ||
| 298 | 'encode_map' => | ||
| 299 | { | ||
| 300 | 'hyph' => { 'yes' => 'SMS', | ||
| 301 | '@' => { 'abbr' => { 'yes' => 'AN' }}} | ||
| 302 | } | ||
| 303 | ); | ||
| 304 | # MERGED ATOM TO DECODE ANY FEATURE VALUE #################### | ||
| 305 | my @fatoms = map {$atoms{$_}} (qw(pos degree gender number case subjobj definite verbform voice form)); | ||
| 306 | $atoms{feature} = $self->create_merged_atom | ||
| 307 | ( | ||
| 308 | 'surfeature' => 'feature', | ||
| 309 | 'atoms' => \@fatoms | ||
| 310 | ); | ||
| 311 | return \%atoms; | ||
| 312 | } | ||
| 313 | |||
| 314 | |||
| 315 | |||
| 316 | #------------------------------------------------------------------------------ | ||
| 317 | # Creates the list of surface features (character positions) that can appear | ||
| 318 | # with particular parts of speech. | ||
| 319 | #------------------------------------------------------------------------------ | ||
| 320 | sub _create_features_pos | ||
| 321 | { | ||
| 322 | my $self = shift; | ||
| 323 | my %features = | ||
| 324 | ( | ||
| 325 | 'NN' => ['gender', 'number', 'definite', 'case', 'form'], | ||
| 326 | 'PM' => ['case', 'form'], | ||
| 327 | 'JJ' => ['degree', 'gender', 'number', 'definite', 'case', 'form'], | ||
| 328 | 'PC' => ['verbform', 'gender', 'number', 'definite', 'case', 'form'], | ||
| 329 | 'DT' => ['gender', 'number', 'definite', 'form'], | ||
| 330 | 'HD' => ['gender', 'number', 'definite', 'form'], | ||
| 331 | 'PN' => ['gender', 'number', 'definite', 'subjobj', 'form'], | ||
| 332 | 'PS' => ['gender', 'number', 'definite', 'form'], | ||
| 333 | 'HP' => ['gender', 'number', 'definite', 'form'], | ||
| 334 | 'HS' => ['definite'], | ||
| 335 | 'RG' => ['gender', 'number', 'definite', 'case', 'form'], | ||
| 336 | 'RO' => ['gender', 'number', 'definite', 'case', 'form'], | ||
| 337 | 'VB' => ['verbform', 'tense', 'voice', 'form'], | ||
| 338 | 'AB' => ['degree', 'form'], | ||
| 339 | 'PP' => ['form'], | ||
| 340 | 'KN' => ['form'], | ||
| 341 | 'PL' => ['form'] | ||
| 342 | ); | ||
| 343 | return \%features; | ||
| 344 | } | ||
| 345 | |||
| 346 | |||
| 347 | |||
| 348 | #------------------------------------------------------------------------------ | ||
| 349 | # Decodes a physical tag (string) and returns the corresponding feature | ||
| 350 | # structure. | ||
| 351 | #------------------------------------------------------------------------------ | ||
| 352 | sub decode | ||
| 353 | { | ||
| 354 | my $self = shift; | ||
| 355 | my $tag = shift; | ||
| 356 | my $fs = Lingua::Interset::FeatureStructure->new(); | ||
| 357 | $fs->set_tagset('sv::suc'); | ||
| 358 | my $atoms = $self->atoms(); | ||
| 359 | my @features = split(/\|/, $tag); | ||
| 360 | foreach my $feature (@features) | ||
| 361 | { | ||
| 362 | $atoms->{feature}->decode_and_merge_hard($feature, $fs); | ||
| 363 | } | ||
| 364 | return $fs; | ||
| 365 | } | ||
| 366 | |||
| 367 | |||
| 368 | |||
| 369 | #------------------------------------------------------------------------------ | ||
| 370 | # Takes feature structure and returns the corresponding physical tag (string). | ||
| 371 | #------------------------------------------------------------------------------ | ||
| 372 | sub encode | ||
| 373 | { | ||
| 374 | my $self = shift; | ||
| 375 | my $fs = shift; # Lingua::Interset::FeatureStructure | ||
| 376 | my $atoms = $self->atoms(); | ||
| 377 | my $pos = $atoms->{pos}->encode($fs); | ||
| 378 | my $features = $self->features_pos()->{$pos}; | ||
| 379 | my @features = ($pos); | ||
| 380 | if(defined($features)) | ||
| 381 | { | ||
| 382 | foreach my $feature (@{$features}) | ||
| 383 | { | ||
| 384 | if(defined($feature) && defined($atoms->{$feature})) | ||
| 385 | { | ||
| 386 | my $value = $atoms->{$feature}->encode($fs); | ||
| 387 | if(defined($value) && $value ne '') | ||
| 388 | { | ||
| 389 | push(@features, $value); | ||
| 390 | } | ||
| 391 | } | ||
| 392 | } | ||
| 393 | } | ||
| 394 | my $tag = join('|', @features); | ||
| 395 | # A few tags have other forms than expected. | ||
| 396 | $tag =~ s:HP\|UTR/NEU\|SIN/PLU\|IND/DEF:HP|-|-|-:; | ||
| 397 | $tag =~ s:(JJ|NN|PC|PS)\|.*\|AN:$1|AN:; | ||
| 398 | $tag =~ s:JJ\|POS\|UTR\|SIN/PLU\|IND/DEF\|SMS:JJ|POS|UTR|-|-|SMS:; | ||
| 399 | $tag =~ s:NN\|UTR/NEU\|SIN/PLU\|IND/DEF$:NN|-|-|-|-:; | ||
| 400 | $tag =~ s:NN\|UTR/NEU\|SIN/PLU\|IND/DEF\|SMS:NN|SMS:; | ||
| 401 | $tag =~ s:NN\|(NEU|UTR)\|SIN/PLU\|IND/DEF$:NN|$1|-|-|-:; | ||
| 402 | $tag =~ s:NN\|(NEU|UTR)\|SIN/PLU\|IND/DEF\|SMS:NN|$1|-|-|SMS:; | ||
| 403 | $tag =~ s:(RG|RO)\|UTR/NEU\|SIN/PLU\|IND/DEF:$1:; | ||
| 404 | return $tag; | ||
| 405 | } | ||
| 406 | |||
| 407 | |||
| 408 | |||
| 409 | #------------------------------------------------------------------------------ | ||
| 410 | # Returns reference to list of known tags. | ||
| 411 | # The source list is the tagset of the Swedish SUC corpus; see also the | ||
| 412 | # UD Swedish treebank. | ||
| 413 | # http://spraakbanken.gu.se/parole/tags.phtml | ||
| 414 | # total tags: | ||
| 415 | # 155 | ||
| 416 | #------------------------------------------------------------------------------ | ||
| 417 | sub list | ||
| 418 | { | ||
| 419 | my $self = shift; | ||
| 420 | my $list = <<end_of_list | ||
| 421 | AB | ||
| 422 | AB|AN | ||
| 423 | AB|KOM | ||
| 424 | AB|POS | ||
| 425 | AB|SMS | ||
| 426 | AB|SUV | ||
| 427 | DT|MAS|SIN|DEF | ||
| 428 | DT|MAS|SIN|IND | ||
| 429 | DT|NEU|SIN|DEF | ||
| 430 | DT|NEU|SIN|IND | ||
| 431 | DT|NEU|SIN|IND/DEF | ||
| 432 | DT|UTR/NEU|PLU|DEF | ||
| 433 | DT|UTR/NEU|PLU|IND | ||
| 434 | DT|UTR/NEU|PLU|IND/DEF | ||
| 435 | DT|UTR/NEU|SIN/PLU|IND | ||
| 436 | DT|UTR/NEU|SIN|DEF | ||
| 437 | DT|UTR/NEU|SIN|IND | ||
| 438 | DT|UTR|SIN|DEF | ||
| 439 | DT|UTR|SIN|IND | ||
| 440 | DT|UTR|SIN|IND/DEF | ||
| 441 | HA | ||
| 442 | HD|NEU|SIN|IND | ||
| 443 | HD|UTR/NEU|PLU|IND | ||
| 444 | HD|UTR|SIN|IND | ||
| 445 | HP|-|-|- | ||
| 446 | HP|NEU|SIN|IND | ||
| 447 | HP|NEU|SIN|IND|SMS | ||
| 448 | HP|UTR/NEU|PLU|IND | ||
| 449 | HP|UTR|SIN|IND | ||
| 450 | HS|DEF | ||
| 451 | IE | ||
| 452 | IN | ||
| 453 | JJ|AN | ||
| 454 | JJ|KOM|UTR/NEU|SIN/PLU|IND/DEF|GEN | ||
| 455 | JJ|KOM|UTR/NEU|SIN/PLU|IND/DEF|NOM | ||
| 456 | JJ|KOM|UTR/NEU|SIN/PLU|IND/DEF|SMS | ||
| 457 | JJ|POS|MAS|SIN|DEF|GEN | ||
| 458 | JJ|POS|MAS|SIN|DEF|NOM | ||
| 459 | JJ|POS|NEU|SIN|IND/DEF|NOM | ||
| 460 | JJ|POS|NEU|SIN|IND|GEN | ||
| 461 | JJ|POS|NEU|SIN|IND|NOM | ||
| 462 | JJ|POS|UTR/NEU|PLU|IND/DEF|GEN | ||
| 463 | JJ|POS|UTR/NEU|PLU|IND/DEF|NOM | ||
| 464 | JJ|POS|UTR/NEU|PLU|IND|NOM | ||
| 465 | JJ|POS|UTR/NEU|SIN/PLU|IND|NOM | ||
| 466 | JJ|POS|UTR/NEU|SIN/PLU|IND/DEF|NOM | ||
| 467 | JJ|POS|UTR/NEU|SIN|DEF|GEN | ||
| 468 | JJ|POS|UTR/NEU|SIN|DEF|NOM | ||
| 469 | JJ|POS|UTR|-|-|SMS | ||
| 470 | JJ|POS|UTR|SIN|IND/DEF|NOM | ||
| 471 | JJ|POS|UTR|SIN|IND|GEN | ||
| 472 | JJ|POS|UTR|SIN|IND|NOM | ||
| 473 | JJ|SUV|MAS|SIN|DEF|GEN | ||
| 474 | JJ|SUV|MAS|SIN|DEF|NOM | ||
| 475 | JJ|SUV|UTR/NEU|PLU|DEF|NOM | ||
| 476 | JJ|SUV|UTR/NEU|PLU|IND|NOM | ||
| 477 | JJ|SUV|UTR/NEU|SIN/PLU|DEF|NOM | ||
| 478 | JJ|SUV|UTR/NEU|SIN/PLU|IND|NOM | ||
| 479 | KN | ||
| 480 | KN|AN | ||
| 481 | MAD | ||
| 482 | MID | ||
| 483 | NN|-|-|-|- | ||
| 484 | NN|AN | ||
| 485 | NN|NEU|-|-|- | ||
| 486 | NN|NEU|-|-|SMS | ||
| 487 | NN|NEU|PLU|DEF|GEN | ||
| 488 | NN|NEU|PLU|DEF|NOM | ||
| 489 | NN|NEU|PLU|IND|GEN | ||
| 490 | NN|NEU|PLU|IND|NOM | ||
| 491 | NN|NEU|SIN|DEF|GEN | ||
| 492 | NN|NEU|SIN|DEF|NOM | ||
| 493 | NN|NEU|SIN|IND|GEN | ||
| 494 | NN|NEU|SIN|IND|NOM | ||
| 495 | NN|SMS | ||
| 496 | NN|UTR|-|-|- | ||
| 497 | NN|UTR|-|-|SMS | ||
| 498 | NN|UTR|PLU|DEF|GEN | ||
| 499 | NN|UTR|PLU|DEF|NOM | ||
| 500 | NN|UTR|PLU|IND|GEN | ||
| 501 | NN|UTR|PLU|IND|NOM | ||
| 502 | NN|UTR|SIN|DEF|GEN | ||
| 503 | NN|UTR|SIN|DEF|NOM | ||
| 504 | NN|UTR|SIN|IND|GEN | ||
| 505 | NN|UTR|SIN|IND|NOM | ||
| 506 | PAD | ||
| 507 | PC|AN | ||
| 508 | PC|PRF|MAS|SIN|DEF|GEN | ||
| 509 | PC|PRF|MAS|SIN|DEF|NOM | ||
| 510 | PC|PRF|NEU|SIN|IND|NOM | ||
| 511 | PC|PRF|UTR/NEU|PLU|IND/DEF|GEN | ||
| 512 | PC|PRF|UTR/NEU|PLU|IND/DEF|NOM | ||
| 513 | PC|PRF|UTR/NEU|SIN|DEF|GEN | ||
| 514 | PC|PRF|UTR/NEU|SIN|DEF|NOM | ||
| 515 | PC|PRF|UTR|SIN|IND|GEN | ||
| 516 | PC|PRF|UTR|SIN|IND|NOM | ||
| 517 | PC|PRS|UTR/NEU|SIN/PLU|IND/DEF|GEN | ||
| 518 | PC|PRS|UTR/NEU|SIN/PLU|IND/DEF|NOM | ||
| 519 | PL | ||
| 520 | PL|SMS | ||
| 521 | PM | ||
| 522 | PM|GEN | ||
| 523 | PM|NOM | ||
| 524 | PM|SMS | ||
| 525 | PN|MAS|SIN|DEF|SUB/OBJ | ||
| 526 | PN|NEU|SIN|DEF|SUB/OBJ | ||
| 527 | PN|NEU|SIN|IND|SUB/OBJ | ||
| 528 | PN|UTR/NEU|PLU|DEF|OBJ | ||
| 529 | PN|UTR/NEU|PLU|DEF|SUB | ||
| 530 | PN|UTR/NEU|PLU|DEF|SUB/OBJ | ||
| 531 | PN|UTR/NEU|PLU|IND|SUB/OBJ | ||
| 532 | PN|UTR/NEU|SIN/PLU|DEF|OBJ | ||
| 533 | PN|UTR|PLU|DEF|OBJ | ||
| 534 | PN|UTR|PLU|DEF|SUB | ||
| 535 | PN|UTR|SIN|DEF|OBJ | ||
| 536 | PN|UTR|SIN|DEF|SUB | ||
| 537 | PN|UTR|SIN|DEF|SUB/OBJ | ||
| 538 | PN|UTR|SIN|IND|SUB | ||
| 539 | PN|UTR|SIN|IND|SUB/OBJ | ||
| 540 | PP | ||
| 541 | PP|AN | ||
| 542 | PS|AN | ||
| 543 | PS|NEU|SIN|DEF | ||
| 544 | PS|UTR/NEU|PLU|DEF | ||
| 545 | PS|UTR/NEU|SIN/PLU|DEF | ||
| 546 | PS|UTR|SIN|DEF | ||
| 547 | RG | ||
| 548 | RG|GEN | ||
| 549 | RG|MAS|SIN|DEF|NOM | ||
| 550 | RG|NEU|SIN|IND|NOM | ||
| 551 | RG|NOM | ||
| 552 | RG|SMS | ||
| 553 | RG|UTR/NEU|SIN|DEF|NOM | ||
| 554 | RG|UTR|SIN|IND|NOM | ||
| 555 | RO|MAS|SIN|IND/DEF|GEN | ||
| 556 | RO|MAS|SIN|IND/DEF|NOM | ||
| 557 | RO|GEN | ||
| 558 | RO|NOM | ||
| 559 | SN | ||
| 560 | UO | ||
| 561 | VB|AN | ||
| 562 | VB|IMP|AKT | ||
| 563 | VB|IMP|SFO | ||
| 564 | VB|INF|AKT | ||
| 565 | VB|INF|SFO | ||
| 566 | VB|KON|PRS|AKT | ||
| 567 | VB|KON|PRT|AKT | ||
| 568 | VB|KON|PRT|SFO | ||
| 569 | VB|PRS|AKT | ||
| 570 | VB|PRS|SFO | ||
| 571 | VB|PRT|AKT | ||
| 572 | VB|PRT|SFO | ||
| 573 | VB|SMS | ||
| 574 | VB|SUP|AKT | ||
| 575 | VB|SUP|SFO | ||
| 576 | end_of_list | ||
| 577 | ; | ||
| 578 | # Protect from editors that replace tabs by spaces. | ||
| 579 | $list =~ s/ \s+/\t/sg; | ||
| 580 | my @list = split(/\r?\n/, $list); | ||
| 581 | pop(@list) if($list[$#list] eq ""); | ||
| 582 | return \@list; | ||
| 583 | } | ||
| 584 | |||
| 585 | |||
| 586 | |||
| 587 | 1; | ||
| 588 | |||
| 589 | __END__ | ||
| 590 | |||
| 591 | =pod | ||
| 592 | |||
| 593 | =encoding UTF-8 | ||
| 594 | |||
| 595 | =head1 NAME | ||
| 596 | |||
| 597 | Lingua::Interset::Tagset::SV::Suc - Driver for the Swedish tagset of the Stockholm-Umeå Corpus. | ||
| 598 | |||
| 599 | =head1 VERSION | ||
| 600 | |||
| 601 | version 3.015 | ||
| 602 | |||
| 603 | =head1 SYNOPSIS | ||
| 604 | |||
| 605 | use Lingua::Interset::Tagset::SV::Suc; | ||
| 606 | my $driver = Lingua::Interset::Tagset::SV::Suc->new(); | ||
| 607 | my $fs = $driver->decode('NN|NEU|SIN|IND|NOM'); | ||
| 608 | |||
| 609 | or | ||
| 610 | |||
| 611 | use Lingua::Interset qw(decode); | ||
| 612 | my $fs = decode('sv::suc', 'NN|NEU|SIN|IND|NOM'); | ||
| 613 | |||
| 614 | =head1 DESCRIPTION | ||
| 615 | |||
| 616 | Interset driver for the Swedish tagset of the Stockholm-Umeå Corpus, | ||
| 617 | L<http://spraakbanken.gu.se/parole/tags.phtml>. | ||
| 618 | |||
| 619 | =head1 SEE ALSO | ||
| 620 | |||
| 621 | L<Lingua::Interset>, | ||
| 622 | L<Lingua::Interset::Tagset>, | ||
| 623 | L<Lingua::Interset::FeatureStructure> | ||
| 624 | |||
| 625 | =head1 AUTHOR | ||
| 626 | |||
| 627 | Dan Zeman <zeman@ufal.mff.cuni.cz> | ||
| 628 | |||
| 629 | =head1 COPYRIGHT AND LICENSE | ||
| 630 | |||
| 631 | This software is copyright (c) 2019 by Univerzita Karlova (Charles University). | ||
| 632 | |||
| 633 | This is free software; you can redistribute it and/or modify it under | ||
| 634 | the same terms as the Perl 5 programming language system itself. | ||
| 635 | |||
| 636 | =cut |