ABSTRACT

Many natural language processing applications involve computing distance metrics to find the closeness of two text documents. Various distance metrics popularly used for text are discussed along with Python examples.

Machine learning models including classic models and neural networks, including the latest Transformers are discussed. Several classic models, as well as cutting-edge models popularly used for natural language processing, are highlighted. Different models are suitable for different tasks. This chapter highlights popular natural language processing applications per model and how to build them using Python.

Once a model is built, proper model evaluation is a critical step that is discussed through a practical lens. Commonly used evaluation metrics and tools and techniques for hyperparameter tuning are shared.