Wrap-up

Natural Language Processing with spaCy

Azadeh Mobasher

Principal data scientist

Chapter 1 - Introduction to NLP and spaCy

 

  • Use spaCy's text processing pipelines to extract linguistic features:

 

spaCy Language pipeline

Natural Language Processing with spaCy

Chapter 2 - spaCy linguistic annotations and word vectors

  • Work with spaCy's classes such as Doc, Token and Span and predict semantic similarities using word vectors:

Analogies and vector operations

Natural Language Processing with spaCy

Chapter 3 - Data analysis with spaCy

  • Write matching patterns to extract terms and phrases using spaCy's Matcher and PhraseMatcher:

 

matcher = Matcher(nlp.vocab)
pattern = [{"LOWER": "good"}, {"LOWER": {"IN": ["morning", "evening"]}}]
matcher.add("morning_greeting", [pattern])

 

matcher = PhraseMatcher(nlp.vocab, attr = "LOWER")
patterns = [nlp.make_doc(term) for term in terms]
matcher.add("InvestmentTerms", patterns)
Natural Language Processing with spaCy

Chapter 4 - Customizing spaCy models

 

  • Annotate and prepare our data for training
  • Train spaCy models and use them at inference time

 

Example of a medical domain NER

Natural Language Processing with spaCy

Recommended resources

Natural Language Processing with spaCy

Congratulations!

Natural Language Processing with spaCy

Preparing Video For Download...