spanish pos python nltk

python - spanish - ¿Cuáles son todas las posibles etiquetas pos de NLTK?



nltk corpus spanish (6)

¿Cómo puedo encontrar una lista con todas las etiquetas de pos posibles utilizadas por Natural Language Toolkit (nltk)?


El conjunto de etiquetas depende del corpus que se utilizó para entrenar al etiquetador. El etiquetador predeterminado de nltk.pos_tag() utiliza el conjunto de etiquetas de Penn Treebank .

En NLTK 2, puede verificar qué etiquetador es el etiquetador predeterminado de la siguiente manera:

import nltk nltk.tag._POS_TAGGER >>> ''taggers/maxent_treebank_pos_tagger/english.pickle''

Eso significa que es un etiquetador de entropía máxima entrenado en el corpus Treebank.

nltk.tag._POS_TAGGER ya no existe en NLTK 3, pero la documentación indica que el etiquetador estándar todavía usa el conjunto de etiquetas de Penn Treebank.


La referencia está disponible en el sitio oficial

Copie y pegue desde allí:

  • CC | Conjunción de coordinación |
  • CD | Número cardinal |
  • DT | Determinador |
  • EX | Existencial allí |
  • FW | Palabra extranjera |
  • IN | Preposición o conjunción subordinada |
  • JJ | Adjetivo |
  • JJR | Adjetivo, comparativo |
  • JJS | Adjetivo, superlativo |
  • LS | Marcador de elemento de lista |
  • MD | Modal |
  • NN | Sustantivo, singular o masivo |
  • NNS | Sustantivo, plural |
  • NNP | Nombre propio, singular |
  • NNPS | Sustantivo propio, plural |
  • PDT | Predeterminador |
  • POS | Final posesivo |
  • PRP | Pronombre personal |
  • PRP $ | Pronombre posesivo |
  • RB | Adverbio |
  • RBR | Adverbio, comparativo |
  • RBS | Adverbio, superlativo |
  • RP | Partícula |
  • SYM | Símbolo |
  • TO | a |
  • UH | Interjección |
  • VB | Verbo, forma base |
  • VBD | Verbo, tiempo pasado |
  • VBG | Verbo, gerundio o participio presente |
  • VBN | Verbo, participio pasado |
  • VBP | Verbo, no presente de tercera persona singular |
  • VBZ | Verbo, tercera persona presente singular |
  • WDT | Determinante de Wh |
  • WP | Wh-pronombre |
  • WP $ | Possessive wh-pronombre |
  • WRB | Wh-adverbio |

Lo siguiente puede ser útil para acceder a un dictado marcado por abreviaturas:

>>> from nltk.data import load >>> tagdict = load(''help/tagsets/upenn_tagset.pickle'') >>> tagdict[''NN''][0] ''noun, common, singular or mass'' >>> tagdict.keys() [''PRP$'', ''VBG'', ''VBD'', ''``'', ''VBN'', '','', "''''", ''VBP'', ''WDT'', ...


Para ahorrarle algo de tiempo a algunas personas, aquí hay una lista que extraje de un pequeño corpus. No sé si está completo, pero debería tener la mayoría (si no todas) de las definiciones de ayuda de upenn_tagset ...

CC : conjunción, coordinación

& ''n and both but either et for less minus neither nor or plus so therefore times v. versus vs. whether yet

CD : número, cardenal

mid-1890 nine-thirty forty-two one-tenth ten million 0.5 one forty- seven 1987 twenty ''79 zero two 78-degrees eighty-four IX ''60s .025 fifteen 271,124 dozen quintillion DM2,000 ...

DT : determinante

all an another any both del each either every half la many much nary neither no some such that the them these this those

EX : existencial allí

there

IN : preposición o conjunción, subordinando

astride among uppon whether out inside pro despite on by throughout below within for towards near behind atop around if like until below next into if beside ...

JJ : adjetivo o numeral, ordinal

third ill-mannered pre-war regrettable oiled calamitous first separable ectoplasmic battery-powered participatory fourth still-to-be-named multilingual multi-disciplinary ...

JJR : adjetivo, comparativo

bleaker braver breezier briefer brighter brisker broader bumper busier calmer cheaper choosier cleaner clearer closer colder commoner costlier cozier creamier crunchier cuter ...

JJS : adjetivo, superlativo

calmest cheapest choicest classiest cleanest clearest closest commonest corniest costliest crassest creepiest crudest cutest darkest deadliest dearest deepest densest dinkiest ...

LS : marcador de elemento de lista

A A. B B. C C. D E F First G H I J K One SP-44001 SP-44002 SP-44005 SP-44007 Second Third Three Two * a b c d first five four one six three two

MD : auxiliar modal

can cannot could couldn''t dare may might must need ought shall should shouldn''t will would

NN : sustantivo, común, singular o masa

common-carrier cabbage knuckle-duster Casino afghan shed thermostat investment slide humour falloff slick wind hyena override subhumanity machinist ...

NNP : sustantivo, propio, singular

Motown Venneboerger Czestochwa Ranzer Conchita Trumplane Christos Oceanside Escobar Kreisler Sawyer Cougar Yvette Ervin ODI Darryl CTCA Shannon A.K.C. Meltex Liverpool ...

NNS : sustantivo, común, plural

undergraduates scotches bric-a-brac products bodyguards facets coasts divestitures storehouses designs clubs fragrances averages subjectivists apprehensions muses factory-jobs ...

PDT : determinante previo

all both half many quite such sure this

POS : marcador genitivo

'' ''s

PRP : pronombre, personal

hers herself him himself hisself it itself me myself one oneself ours ourselves ownself self she thee theirs them themselves they thou thy us

PRP $: pronombre, posesivo

her his mine my our ours their thy your

RB : adverbio

occasionally unabatingly maddeningly adventurously professedly stirringly prominently technologically magisterially predominately swiftly fiscally pitilessly ...

RBR : adverbio, comparativo

further gloomier grander graver greater grimmer harder harsher healthier heavier higher however larger later leaner lengthier less- perfectly lesser lonelier longer louder lower more ...

RBS : adverbio, superlativo

best biggest bluntest earliest farthest first furthest hardest heartiest highest largest least less most nearest second tightest worst

RP : partícula

aboard about across along apart around aside at away back before behind by crop down ever fast for forth from go high i.e. in into just later low more off on open out over per pie raising start teeth that through under unto up up-pp upon whole with you

TO : "a" como preposición o marcador de infinitivo

to

UH : interjección

Goodbye Goody Gosh Wow Jeepers Jee-sus Hubba Hey Kee-reist Oops amen huh howdy uh dammit whammo shucks heck anyways whodunnit honey golly man baby diddle hush sonuvabitch ...

VB : verbo, forma base

ask assemble assess assign assume atone attention avoid bake balkanize bank begin behold believe bend benefit bevel beware bless boil bomb boost brace break bring broil brush build ...

VBD : verbo, tiempo pasado

dipped pleaded swiped regummed soaked tidied convened halted registered cushioned exacted snubbed strode aimed adopted belied figgered speculated wore appreciated contemplated ...

VBG : verbo, participio presente o gerundio

telegraphing stirring focusing angering judging stalling lactating hankerin'' alleging veering capping approaching traveling besieging encrypting interrupting erasing wincing ...

VBN : verbo, participio pasado

multihulled dilapidated aerosolized chaired languished panelized used experimented flourished imitated reunifed factored condensed sheared unsettled primed dubbed desired ...

VBP : verbo, tiempo presente, no tercera persona singular

predominate wrap resort sue twist spill cure lengthen brush terminate appear tend stray glisten obtain comprise detest tease attract emphasize mold postpone sever return wag ...

VBZ : verbo, tiempo presente, tercera persona singular

bases reconstructs marks mixes displeases seals carps weaves snatches slumps stretches authorizes smolders pictures emerges stockpiles seduces fizzes uses bolsters slaps speaks pleads ...

WDT : WH-determiner

that what whatever which whichever

WP : WH-pronombre

that what whatever whatsoever which who whom whosoever

WRB : Wh-adverbio

how however whence whenever where whereby whereever wherein whereof why



El libro tiene una nota sobre cómo encontrar ayuda en los conjuntos de etiquetas, por ejemplo:

nltk.help.upenn_tagset()

Otros son probablemente similares. (Nota: quizás primero tagsets descargar los tagsets de tagsets de la sección Modelos de ayudantes de descarga para esto)