TasksSotADatasetsPapersMethodsSubmitAbout
Papers With Code 2

A community resource for machine learning research: papers, code, benchmarks, and state-of-the-art results.

Explore

Notable BenchmarksAll SotADatasetsPapersMethods

Community

Submit ResultsAbout

Data sourced from the PWC Archive (CC-BY-SA 4.0). Built by the community, for the community.

Papers/ELECTRA and GPT-4o: Cost-Effective Partners for Sentiment ...

ELECTRA and GPT-4o: Cost-Effective Partners for Sentiment Analysis

James P. Beno

2024-12-29Sentiment AnalysisSentiment Classification
PaperPDFCode(official)

Abstract

Bidirectional transformers excel at sentiment analysis, and Large Language Models (LLM) are effective zero-shot learners. Might they perform better as a team? This paper explores collaborative approaches between ELECTRA and GPT-4o for three-way sentiment classification. We fine-tuned (FT) four models (ELECTRA Base/Large, GPT-4o/4o-mini) using a mix of reviews from Stanford Sentiment Treebank (SST) and DynaSent. We provided input from ELECTRA to GPT as: predicted label, probabilities, and retrieved examples. Sharing ELECTRA Base FT predictions with GPT-4o-mini significantly improved performance over either model alone (82.50 macro F1 vs. 79.14 ELECTRA Base FT, 79.41 GPT-4o-mini) and yielded the lowest cost/performance ratio (\$0.12/F1 point). However, when GPT models were fine-tuned, including predictions decreased performance. GPT-4o FT-M was the top performer (86.99), with GPT-4o-mini FT close behind (86.70) at much less cost (\$0.38 vs. \$1.59/F1 point). Our results show that augmenting prompts with predictions from fine-tuned encoders is an efficient way to boost performance, and a fine-tuned GPT-4o-mini is nearly as good as GPT-4o FT at 76% less cost. Both are affordable options for projects with limited resources.

Results

TaskDatasetMetricValueModel
Sentiment AnalysisSST-3Macro F175.68GPT-4o-mini Fine-Tuned
Sentiment AnalysisSST-3Macro F173.99GPT-4o Fine-Tuned (Minimal)
Sentiment AnalysisSST-3Macro F172.94GPT-4o + ELECTRA Large FT
Sentiment AnalysisSST-3Macro F172.2GPT-4o (Prompt)
Sentiment AnalysisSST-3Macro F172.06GPT-4o + ELECTRA Large FT (Prompt, Label, Examples)
Sentiment AnalysisSST-3Macro F171.98GPT-4o-mini + ELECTRA Large FT (Prompt, Label, Examples)
Sentiment AnalysisSST-3Macro F171.72GPT-4o-mini + ELECTRA Base FT
Sentiment AnalysisSST-3Macro F170.99GPT-4o-mini + ELECTRA Large FT (Prompt, Label)
Sentiment AnalysisSST-3Macro F170.9ELECTRA Large Fine-Tuned
Sentiment AnalysisSST-3Macro F170.67GPT-4o-mini (Prompt)
Sentiment AnalysisSST-3Macro F169.95ELECTRA Base Fine-Tuned
Sentiment AnalysisSentiment MergedMacro F186.99GPT-4o Fine-Tuned (Minimal)
Sentiment AnalysisSentiment MergedMacro F186.77GPT-4o-mini Fine-Tuned
Sentiment AnalysisSentiment MergedMacro F183.49GPT-4o-mini + ELECTRA Large FT (Prompt, Label)
Sentiment AnalysisSentiment MergedMacro F183.09GPT-4o + ELECTRA Large FT (Prompt, Label, Examples)
Sentiment AnalysisSentiment MergedMacro F182.74GPT-4o-mini + ELECTRA Base FT (Prompt, Label)
Sentiment AnalysisSentiment MergedMacro F182.36ELECTRA Large Fine-Tuned
Sentiment AnalysisSentiment MergedMacro F181.57GPT-4o + ELECTRA Large FT (Prompt, Label)
Sentiment AnalysisSentiment MergedMacro F180.14GPT-4o (Prompt)
Sentiment AnalysisSentiment MergedMacro F179.52GPT-4o-mini (Prompt)
Sentiment AnalysisSentiment MergedMacro F179.29ELECTRA Base Fine-Tuned
Sentiment AnalysisDynaSentMacro F189GPT-4o Fine-Tuned (Minimal)
Sentiment AnalysisDynaSentMacro F186.9GPT-4o-mini Fine-Tuned
Sentiment AnalysisDynaSentMacro F181.53GPT-4o + ELECTRA Large FT (Prompt, Label, Examples)
Sentiment AnalysisDynaSentMacro F180.22GPT-4o (Prompt)
Sentiment AnalysisDynaSentMacro F179.72GPT-4o-mini + ELECTRA Large FT (Prompt, Label, Probabilities)
Sentiment AnalysisDynaSentMacro F177.94GPT-4o-mini + ELECTRA Large FT (Prompt, Label)
Sentiment AnalysisDynaSentMacro F177.69GPT-4o + ELECTRA Large FT
Sentiment AnalysisDynaSentMacro F177.35GPT-4o-mini (Prompt)
Sentiment AnalysisDynaSentMacro F176.29ELECTRA Large Fine-Tuned
Sentiment AnalysisDynaSentMacro F176.19GPT-4o-mini + ELECTRA Base FT
Sentiment AnalysisDynaSentMacro F171.83ELECTRA Base Fine-Tuned

Related Papers

AdaptiSent: Context-Aware Adaptive Attention for Multimodal Aspect-Based Sentiment Analysis2025-07-17AI Wizards at CheckThat! 2025: Enhancing Transformer-Based Embeddings with Sentiment for Subjectivity Detection in News Articles2025-07-15DCR: Quantifying Data Contamination in LLMs Evaluation2025-07-15SentiDrop: A Multi Modal Machine Learning model for Predicting Dropout in Distance Learning2025-07-14GNN-CNN: An Efficient Hybrid Model of Convolutional and Graph Neural Networks for Text Representation2025-07-10FINN-GL: Generalized Mixed-Precision Extensions for FPGA-Accelerated LSTMs2025-06-25Unpacking Generative AI in Education: Computational Modeling of Teacher and Student Perspectives in Social Media Discourse2025-06-19Characterizing Linguistic Shifts in Croatian News via Diachronic Word Embeddings2025-06-16