NLP Explained: The 5-Step Pipeline You Need to Memorize

tutorial 5 July 2026 6 min read

NLP Explained — The 5-Step Pipeline You Need to Memorize

Natural Language Processing questions on CCAT often test one specific thing: whether you know the 5-step pipeline and can identify which step a given example belongs to. Let’s lock that in.

What Is NLP?

NLP is the branch of AI focused on enabling machines to read, interpret, and generate human language. It splits into two halves:

NLP System
├── NLU (Natural Language Understanding) → Reading / Interpreting meaning
└── NLG (Natural Language Generation)     → Writing / Producing responses

Exam trap: NLU is about understanding input; NLG is about producing output. A question asking “Which component handles sentiment analysis?” → NLU. “Which component handles autocomplete or chatbot replies?” → NLG.

The 5-Step NLP Pipeline

This sequence is a favorite for match-the-following and fill-in-the-blank questions:

StepNameWhat It DoesExample
1Lexical AnalysisBreaks text into sentences/words“The cat sat” → [“The”, “cat”, “sat”]
2Syntactic AnalysisChecks grammar/structure“The school goes to boy” → rejected
3Semantic AnalysisExtracts literal/dictionary meaning“Bank” (river) vs. “bank” (money)
4Discourse IntegrationMeaning depends on surrounding sentences“It was delicious” — what was?
5Pragmatic AnalysisInterprets real-world intent“Can you pass the salt?” = a request, not a literal question

Memory trick: LSSDP — Lexical, Syntactic, Semantic, Discourse, Pragmatic. Say it as “Less Stress, Study Daily, Pass.”

Key NLP Techniques — Match Them Correctly

TechniqueDescription
TokenizationSplitting text into words/sentences/subwords
Stop Word RemovalRemoving common filler words (the, is, at)
StemmingCrude root reduction: “running” → “run”
LemmatizationDictionary-accurate base form: “better” → “good”
POS TaggingLabeling words as noun/verb/adjective
NERIdentifying names, organizations, dates, locations

Common exam trap: Stemming vs. Lemmatization. Stemming is faster but cruder (can produce non-words); Lemmatization is slower but grammatically accurate. If a question emphasizes “dictionary-correct” output, the answer is Lemmatization.

Transformer Architecture — The Modern Backbone of NLP

Introduced in the 2017 paper “Attention Is All You Need” (Google), Transformers replaced RNNs as the dominant NLP architecture by using self-attention — allowing every word to directly relate to every other word, and enabling parallel (not sequential) processing.

ModelDeveloperKey Feature
BERTGoogleBidirectional; strong at understanding
GPT-3/4OpenAIGenerative; strong at text generation
T5GoogleText-to-text transfer transformer

Exam trap: BERT is primarily for understanding tasks (bidirectional context), while GPT is primarily generative (predicts the next word). Don’t mix these up on a “which model is best for X” question.

Quick Recap

  • NLU = understanding, NLG = generation
  • Pipeline order: Lexical → Syntactic → Semantic → Discourse → Pragmatic
  • Stemming = crude/fast, Lemmatization = accurate/dictionary-based
  • Transformers use self-attention, not recurrence

Next post: Computer Vision — the CV pipeline and how it differs from plain image classification.