Evidence map›Paper›PMID 41092067›Full record

ArticleJMIR formative research2025

Evaluating Large Language Models for Sentiment Analysis and Hesitancy Analysis on Vaccine Posts From Social Media: Qualitative Study.

Augustine Annan, Amanda L Eiden, Dong Wang, Jingcheng Du, Majid Rastegar-Mojarad, Varun Kumar Nomula, Xiaoyan Wang

Abstract read
In one paragraph

Article in JMIR formative research, 2025. The graph could read no effect estimate from its abstract, so it casts no vote on the map. Cited by 2 papers.

0numbers the graph read from it
0cells of the map it votes in
2citing papers in PubMed
–field-weighted citation impact
1 · What the graph read from it

What it found

Each row is one number read from the abstract, on the scale the paper reported it, with its interval. Left of the dashed line favours the treatment, right favours the comparator. Under each row is the sentence it came from. New to these charts? A ten-minute tutorial.

The abstract states no effect estimate the extractor could read, or names no intervention and outcome on the map, so this paper lights no cell and moves no belief. It is still indexed, cited and linked below.

2 · The registry

The trial behind it

Trials whose registry record cites this paper, or whose number appears in the abstract. A trial that started after this paper was published is citing it as background, not reporting it.

Neither the registry nor the abstract names a trial number. If this is a trial report, that itself is worth knowing.

3 · Its place in the literature

Who cites it

2 citing papers in PubMed.

  1. Article
  2. Article
4 · The record

Corrections and comments

PubMed lists nothing against this paper. Absence here is not a guarantee, only a check that was made.

5 · Who and what money

Authors and funding

7 authors.

Augustine AnnanIMO Health, Rosemont, IL, United States.ORCID 0000-0002-2696-6765
Amanda L EidenMerck & Co, Inc, 126 East Lincoln Avenue, Rahway, NJ, 07065, United States, 1 267-305-0672.ORCID 0000-0001-9422-1215
Dong WangMerck & Co, Inc, 126 East Lincoln Avenue, Rahway, NJ, 07065, United States, 1 267-305-0672.ORCID 0009-0003-3322-6284
Jingcheng DuIMO Health, Rosemont, IL, United States.ORCID 0000-0002-0322-4566
Majid Rastegar-MojaradIMO Health, Rosemont, IL, United States.ORCID 0000-0001-6962-3554
Varun Kumar NomulaMerck & Co, Inc, 126 East Lincoln Avenue, Rahway, NJ, 07065, United States, 1 267-305-0672.ORCID 0009-0007-6710-6239
Xiaoyan WangIMO Health, Rosemont, IL, United States.ORCID 0000-0002-4193-4120

Funding

No grant is acknowledged in the PubMed record.

6 · The paper itself

Abstract

Background: In the digital age, social media has become a crucial platform for public discourse on diverse health-related topics, including vaccines. Efficient sentiment analysis and hesitancy detection are essential for understanding public opinions and concerns. Large language models (LLMs) offer advanced capabilities for processing complex linguistic patterns, potentially providing valuable insights into vaccine-related discourse. Objective: This study aims to evaluate the performance of various LLMs in sentiment analysis and hesitancy detection related to vaccine discussions on social media and identify the most efficient, accurate, and cost-effective model for detecting vaccine-related public sentiment and hesitancy trends. Methods: We used several LLMs-generative pretrained transformer (GPT-3.5), GPT-4, Claude-3 Sonnet, and Llama 2-to process and classify complex linguistic data related to human papillomavirus; measles, mumps, and rubella; and vaccines overall from X (formerly known as Twitter), Reddit, and YouTube. The models were tested across different learning paradigms: zero-shot, 1-shot, and few-shot to determine their adaptability and learning efficiency with varying amounts of training data. We evaluated the models' performance using accuracy, F1-score, precision, and recall. In addition, we conducted a cost analysis focused on token usage to assess the computational efficiency of each approach. Results: GPT-4 (F1-score=0.85 and accuracy=0.83) outperformed GPT-3.5, Llama 2, and Claude-3 Sonnet across various metrics, regardless of the sentiment type or learning paradigm. Few-shot learning did not significantly enhance performance compared with the zero-shot paradigm. Moreover, the increased computational costs and token usage associated with few-shot learning did not justify its application, given the marginal improvement in model performance. The analysis highlighted challenges in classifying neutral sentiments and convenience, correctly interpreting sarcasm, and accurately identifying indirect expressions of vaccine hesitancy, emphasizing the need for model refinement. Conclusions: GPT-4 emerged as the most accurate model, excelling in sentiment and hesitancy analysis. Performance differences between learning paradigms were minimal, making zero-shot learning preferable for its balance of accuracy and computational efficiency. However, the zero-shot GPT-4 model is not the most cost-effective compared with traditional machine learning. A hybrid approach, using LLMs for initial annotation and traditional models for training, could optimize cost and performance. Despite reliance on specific LLM versions and a limited focus on certain vaccine types and platforms, our findings underscore the capabilities and limitations of LLMs in vaccine sentiment and hesitancy analysis, highlighting the need for ongoing evaluation and adaptation in public health communication strategies.

Indexed as

LanguageSocial MediaVaccination HesitancyVaccinesHumansLarge Language ModelsQualitative ResearchVaccinesartificial intelligencecomputational efficiencyGPT4hesitancy analysislanguage modelslarge language modelsLLMsmachine learningNLPpublic health communicationpublic opinionpublic sentimentsentiment analysissocial mediasocial media platformsvaccinevaccine hesitancyvaccine postsvaccine-relatedvaccine sentiment

Identifiers

PMID41092067
PMCPMC12526656

What OpenQuestion holds

Textmetadata
LicenceCC BY
Read underepoch 390

Registered trials

None linked

Read under generation 80e0d062 · epoch 390. Bibliography from PubMed, PubMed Central and OpenAlex; grants from NIH RePORTER; trial links from ClinicalTrials.gov; estimates, votes and beliefs from the OpenQuestion graph.