Natural Language Processing

Understanding Machine Learning

Sara Billen

Curriculum Manager at DataCamp

Natural Language Processing (NLP)

The ability for computers to understand the meaning of human language

Understanding Machine Learning

Bag of words

Bag of Words

Understanding Machine Learning

Bag of words

"U2 is a great band"

Word Count
U2 1
Queen 0
is 1
a 1
great 1
band 1

"Queen is a great band"

Word Count
U2 0
Queen 1
is 1
a 1
great 1
band 1
Understanding Machine Learning

Bag of words: n-grams

"That book is not great"

Word Count
That 1
book 1
is 1
not 1
great 1

2-gram (bi-gram)

Word Count
That book 1
book is 1
is not 1
not great 1
Understanding Machine Learning

Bag of words: limitations

  • Word counts don't help us consider synonyms
  • Example: "blue"
    • "sky-blue"
    • "aqua"
    • "cerulean"
  • Want to group as a single feature

blue

Understanding Machine Learning

Word embeddings

Word embeddings

  • Create features that group similar words
  • Features have a mathematical meaning:

$$

king - man + woman = queen

Understanding Machine Learning

Language translation

Translation with neural network

Understanding Machine Learning

Applications

  • Language translation
  • Chatbots
  • Personal assistants
  • Sentiment analysis
  • ...

Man chatting with chat bot on smartphone

Understanding Machine Learning

Deep learning

  • Two types of problems
    • Computer vision
    • Natural language processing
  • Why deep learning?
    • Complex problems
    • Automatic feature extraction
    • Lots of data

Understanding Machine Learning

Let's practice!

Understanding Machine Learning

Preparing Video For Download...