Bird
0
0

When integrating FastText embeddings into a deep learning model for text classification, which method best handles out-of-vocabulary (OOV) words during inference?

hard📝 Application Q9 of 15
NLP - Word Embeddings
When integrating FastText embeddings into a deep learning model for text classification, which method best handles out-of-vocabulary (OOV) words during inference?
AUse FastText's subword vectors to generate embeddings for OOV words on the fly
BReplace OOV words with a fixed <UNK> token embedding
CIgnore OOV words during embedding lookup
DTrain a separate embedding layer only on the training vocabulary
Step-by-Step Solution
Solution:
  1. Step 1: Understand OOV problem

    Out-of-vocabulary words lack pretrained embeddings in traditional models.
  2. Step 2: FastText's advantage

    FastText uses character n-grams, enabling it to compute embeddings for unseen words dynamically.
  3. Step 3: Compare options

    Replacing with loses information; ignoring words loses context; separate embedding layer doesn't solve OOV.
  4. Final Answer:

    Use FastText's subword vectors to generate embeddings for OOV words on the fly -> Option A
  5. Quick Check:

    Subword embeddings handle OOV effectively [OK]
Quick Trick: FastText subwords enable OOV embedding generation [OK]
Common Mistakes:
MISTAKES
  • Using fixed token embedding for OOV
  • Ignoring OOV words in input
  • Training embeddings only on known vocabulary

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More NLP Quizzes