Multilabel classification using LLMs

Refer this: Google Colab

This notebook is available in the Hugging Face documentation of Llama2 model ( Llama2 (huggingface.co)), and I think this is the most appropriate way for text classification if you want to use Decoder only models for text classification tasks.

RAG and AutoModelForSequenceClassification head on top of these decoder only LLMs, won’t give the best results for text classification.

1 Like