Machine learning models are trained to perform particular tasks. Classification is one of these tasks. Classification involves training a model to label a piece of text. The canonical example is of spam classification - based on the contents of the email, the model can determine whether the email is spam or not.
In the context of Legal AI and Legal NLP, classification is of particular interest when working with clauses or large collections of documents. Machine learning can be used to train clause classification models to classify and identify particular types of clauses in a legal document. Machine learning can also be used to train document classification models to classify and organise documents against a pre-defined taxonomy.