Distilled ChatGPT Topic & Sentiment Modeling with Applications in Finance

Olivier Gandouet, Mouloud Belbahri, Armelle Jezequel, Yuriy BodjovarXiv 2024 · DOI · arXiv

Introduction

Quarterly earnings calls represent a critical information source for financial markets, yet their sheer volume presents a significant challenge for systematic analysis. With approximately 60 million sentences generated annually across thousands of global companies, manual processing is unfeasible. While Large Language Models (LLMs) like ChatGPT demonstrate exceptional capabilities in text classification and summarization, their deployment for large-scale quantitative investing is hindered by high computational costs, latency, and the risk of "hallucinations."

Traditional natural language processing (NLP) methods, such as Latent Dirichlet Allocation (LDA), often lack the nuance required for complex financial discourse. To bridge this gap, researchers from TD Asset Management and Layer 6 AI have proposed a Knowledge Distillation (KD) framework. This approach leverages the sophisticated reasoning of a "Teacher" LLM to train a lightweight, high-performance "Student" model tailored for the financial domain.

Methodology: The Teacher-Student Framework

The core of the research involves a multi-stage pipeline designed to transfer expertise from ChatGPT to a smaller transformer-based model, specifically MPNet.

The Teacher-Student framework for distilling financial knowledge from a Large Language Model into a specialized classifier.

1. Topic Discovery and Refinement

Rather than imposing a rigid, pre-defined taxonomy, the researchers allowed ChatGPT to identify relevant financial categories from a random sample of earnings call sentences. This generated an initial list of approximately 100 raw topics, which were subsequently refined using k-means clustering on sentence embeddings and frequency filtering to establish a robust core set of financial themes.

2. Automated Data Labeling

Using the refined topic list, ChatGPT (acting as the Teacher) labeled a dataset of 80,000 sentences. Each sentence was tagged with both a primary topic and a sentiment orientation (Positive, Neutral, or Negative). To ensure data integrity, regular expressions were employed to filter out any responses that deviated from the requested format, effectively mitigating LLM hallucinations.

3. Student Model Training

The final stage involved training the "Student" model—MPNet—on the ChatGPT-labeled corpus. By appending a Multi-Layer Perceptron (MLP) head to the MPNet architecture, the researchers created a specialized classifier that mimics the Teacher's logic while operating at a fraction of the computational overhead.

Experimental Results

To validate the effectiveness of the distillation process, the models were tested against a "ground truth" benchmark of 1,000 sentences manually annotated by three financial experts.

  • Sentiment Accuracy: The distilled MPNet model achieved a 77.8% $F_1$ score, significantly outperforming FinBERT (65.3%), a widely used model pre-trained specifically on financial text. This suggests that supervised learning from a general-purpose LLM can be more effective than domain-specific pre-training on smaller, noisier datasets.
  • Topic Identification: The student model reached a 72.8% $F_1$ score. While slightly lower than the raw performance of ChatGPT 3.5 (83.1%), the student model offers a superior balance of accuracy and deployment efficiency, with a model size of approximately 420MB.

Financial Insights and Applications

The practical utility of the distilled model was demonstrated through an analysis of historical earnings call data from 2010 to 2023. One of the most compelling findings involved the "Dividend Skepticism" phenomenon.

Cumulative Information Coefficient (IC) for topic occurrences and sentiment across different financial categories, illustrating the predictive power of the model.

As shown in the cumulative IC charts, while the frequency of executive discussion regarding "Dividends & Buybacks" generally correlates with positive stock returns, the sentiment expressed in those discussions can be a contrarian indicator. Specifically, highly positive sentiment in this category sometimes correlated negatively with future returns, suggesting that investors may discount overly optimistic rhetoric regarding capital returns in favor of more objective metrics.

Conclusion

This research demonstrates that knowledge distillation provides a viable path for integrating LLM-level intelligence into production-grade financial workflows. By using ChatGPT as a high-fidelity labeler, researchers can build specialized models that are fast, cost-effective, and more accurate than previous industry standards like FinBERT. Future work will focus on multi-label classification and incorporating broader contextual cues from neighboring sentences to further refine the model's understanding of complex corporate narratives.

Summary updated

Abstract

In this study, ChatGPT is utilized to create streamlined models that generate easily interpretable features. These features are then used to evaluate financial outcomes from earnings calls. We detail a training approach that merges knowledge distillation and transfer learning, resulting in lightweight topic and sentiment classification models without significant loss in accuracy. These models are assessed through a dataset annotated by experts. The paper also delves into two practical case studies, highlighting how the generated features can be effectively utilized in quantitative investing scenarios.
BibTeX
@misc{gandouet2024distilled,
  author = {Olivier Gandouet and Mouloud Belbahri and Armelle Jezequel and Yuriy Bodjov},
  title = {{Distilled ChatGPT Topic \& Sentiment Modeling with Applications in Finance}},
  year = {2024},
  eprint = {2403.02185},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2403.02185},
}
Figure