Search for a command to run...
In natural language processing, an important objective is to perform sentiment analysis, which involves categorizing textual content based on whether it expresses a positive, negative, or neutral sentiment. Sentiment analysis systems face challenges such as ambiguity, subjectivity, contextual understanding, and domain adaptation. These challenges make accurately determining sentiment in text a complex task. To address these challenges, the proposed objective for sentiment analysis on movie review datasets is to develop a transfer learning-based XLNet model. The utilization of transformer-based models has resulted in notable advancements across several NLP tasks in recent years. In this work, the feasibility of employing the XLNet model for sentiment analysis is examined, which involves fine-tuning the XLNet model on a labeled sentiment analysis dataset. First, the dataset is preprocessed, and the XLNet model is loaded. In addition, the classification layer is added to the model and transfer learning is applied for fine-tuning on the sentiment analysis dataset. The effectiveness of the proposed work is evaluated on a test set, and various metrics such as accuracy, precision, recall, and F1 score are reported. Experimental results indicate that the XLNet model attained goood results than other transformer based models on movie review dataset for sentiment analysis and it shows the effectiveness of transfer learning with XLNet in the sentiment analysis domain.