NLP Starter
Text into numbers, from tokenization and n-grams to TF-IDF, edit distance, and attention. You will build the preprocessing pipeline behind search engines and language models with plain Python. Start here if you want to understand what happens before a model sees a sentence.
Your progress
0/27 · 0%Path readiness 0%Easy 0% · Medium 0% · Hard 0%
Continue path · TokenizationWhat you will learn
- Tokenize, normalize, and build vocabularies from raw text
- Represent documents with bag-of-words, TF-IDF, and similarity scores
- Build n-gram language models with smoothing and subword tokenization
- Retrieve documents and score generated text
1Tokens and Text Normalization
Turn raw strings into tokens: whitespace and punctuation handling, stopword removal, n-grams, vocabulary indices, one-hot encoding, and sentence splitting.
- TokenizationEasynlp-001NLP
- Easy
- Stopword RemovalEasynlp-009NLP
- Easy
- Vocabulary Index MappingEasynlp-014NLP
- One-Hot Token EncodingEasynlp-015NLP
- Most Common TokenEasynlp-017NLP
- Sentence SplitterMediumnlp-019NLP
Stage checkpoint
0/2 to passA checkpoint is a short retrieval test drawn from this stage: solve 2 of 3 from memory to mark the stage complete. The stage stays open either way.
- One-Hot Token EncodingEasy
- Most Common TokenEasy
- Sentence SplitterMedium
2Document Representations
Documents as vectors: bag-of-words, TF-IDF, cosine similarity, offset tokenization, Jaccard and Dice overlap, and PMI collocation scores.
- Bag of WordsEasynlp-002NLP
- Medium
- Medium
- Medium
- Jaccard Token SimilarityMediumnlp-035NLP
- Medium
- PMI Collocation ScoreMediumnlp-059NLP
Stage checkpoint
0/2 to passA checkpoint is a short retrieval test drawn from this stage: solve 2 of 3 from memory to mark the stage complete. The stage stays open either way.
- Jaccard Token SimilarityMedium
- Dice Coefficient of TokensMedium
- PMI Collocation ScoreMedium
3Language Models
Predict the next token: BPE merges and encoding, bigram probabilities with Laplace smoothing, log-likelihood, backoff, and WordPiece segmentation.
- BPE Merge StepMediumnlp-020NLP
- Medium
- Medium
- BPE Encode with MergesHardnlp-021NLP
- Hard
- Backoff ProbabilityHardnlp-029NLP
Stage checkpoint
0/2 to passA checkpoint is a short retrieval test drawn from this stage: solve 2 of 3 from memory to mark the stage complete. The stage stays open either way.
4Search and Evaluation
Find and judge text: edit distance, inverted indexes, BM25, log-likelihood ratio collocations, scaled dot-product attention, and ROUGE-2.
- Levenshtein Edit DistanceMediumnlp-031NLP
- Build an Inverted IndexMediumnlp-041NLP
- Hard
- Hard
- Hard
- ROUGE-2 F1Hardnlp-092NLP
Stage checkpoint
0/2 to passA checkpoint is a short retrieval test drawn from this stage: solve 2 of 3 from memory to mark the stage complete. The stage stays open either way.
Capstone
ProjectClose the path with one real artifact from the catalog.
Take the tokenization and TF-IDF documents from this path all the way to ranked search.