Emotion Classification From Text With Large Language Models

Loading...
Thumbnail Image

Files

URL

Journal Title

Journal ISSN

Volume Title

Perustieteiden korkeakoulu | Bachelor's thesis
Electronic archive copy is available locally at the Harald Herlin Learning Centre. The staff of Aalto University has access to the electronic bachelor's theses by logging into Aaltodoc with their personal Aalto user ID. Read more about the availability of the bachelor's theses.

Department

Major/Subject

Mcode

SCI3095

Language

en

Pages

23+3

Series

Abstract

Emotion classification from text is an important text classification task with potential applications in text-to-speech systems, social networks, customer support, robotics and empathetic AI. Traditionally, similar to most other text classification problems, it is performed with machine learning and deep learning methods, such as linear support vector classifiers and sequence classification transformers. This thesis aims to determine the feasibility of using large language models (LLMs) for emotion classification from text. As opposed to traditional methods, this approach does not require any labeled training data. This opens a possibility to apply LLMs in classification scenarios where the data is scarce or difficult to collect. The thesis has shown that Gemini 2.5 Flash and GPT-4.1 LLMs outperform a support vector classifier with TF-IDF features on the ISEAR dataset. It has also determined that utilizing few-shot prompting, reasoning models, and structured output positively affects the classification performance. These results suggest that LLMs can be effective alternatives for emotion classification, yet underscore the importance of prompting and inference techniques in achieving reliable results.

Description

Supervisor

Korpi-Lagg, Maarit

Thesis advisor

Saukkoriipi, Mikko

Other note

Citation