Notes

Part-of-Speech (POS) Tagging

"Book" is a noun in "read the book" and a verb in "book the flight". Nothing in the letters tells you which — only the company the word keeps. Deciding that, for every word in a sentence, is the task.

A label for every token
Part-of-speech tagging assigns each token a grammatical category from a fixed tagset, and which tagset you choose shapes everything downstream:

  • The Penn Treebank set is fine-grained and English-specific, separating past-tense verbs from third-person singular present ones.
  • Universal Dependencies uses seventeen coarse tags defined to mean the same thing in every language, which is what makes a multilingual pipeline possible at all.

From Viterbi to transformers
Early taggers were hidden Markov models decoded with the Viterbi algorithm; then came CRFs over hand-built features, and now neural sequence labellers reading contextual embeddings. Accuracy on well-edited English sits around 97%, but the remaining errors are not spread evenly — they cluster on words the tagger never saw in training, on genuinely ambiguous constructions, and on text that looks nothing like a newspaper. Run spaCy or NLTK over tweets or clinical notes and the gap shows up immediately.

What depends on it
A lemmatiser cannot decide whether "saw" reduces to "see" or stays a noun without the tag. Keyword extraction that keeps only nouns and proper nouns, chunking into noun phrases, dependency parsing and rule-based extraction all read this layer. Large models answer many end tasks without an explicit tagger, but where you need an inspectable account of why a sentence was analysed one way, the tag sequence is where you look.

Part-of-speech tagging labels every token in a text with its grammatical category — noun, verb, adjective, determiner — resolving ambiguity from context, since a form like "book" can be either noun or verb. Tagsets range from the fine-grained Penn Treebank set to the cross-lingual Universal Dependencies tags. Lemmatisation, noun-phrase chunking, dependency parsing and keyword extraction all read this layer; without it, each downstream step must guess a word's grammatical role.

Remember being taught to underline the nouns and circle the verbs in a sentence? That schoolroom exercise has a serious use.

Part-of-speech tagging is software going through a sentence and labelling each word with its job — this one names a thing, that one describes an action, this one just points. It sounds trivial until you notice that the same word changes job depending on where it sits. "Book" is a thing in "read the book" and an action in "book a table". Getting those labels right is how a program works out which words carry the topic of a document, and how a search tool knows that "running" and "ran" are the same underlying verb.