NLP Part 4 - Contextual Embedding

NLP Part 4 - Contextual Embedding In the last article ( https://medium.com/@umbertofontana/nlp-part-4-toxic-comments-classification-10e7167fa50b ) we used the word/sentence embedding technique combined with Logistic Regression to classify the toxicity of a text among 6 possible labels. It seems like we can conclude this series of articles since these methods are very effective and create a global word representation for a machine to understand. Well, wrong… Remember that the research to arrive at chatGPT was long and passed through many little steps. In this article, I will talk about contextual embedding with a main focus on two models: Seq2seq and ELMo. Context Matters Yes, our language (doesn’t matter which language) is way more complicated. If I search for a translation from Italian to English of the word “ campagna ” I obtain the following: Country, countryside, rural area ; Land, farmland ; Campaign, offensive ; Promotion, campaign ; Effectively, even in the translations abo...