mlsanityData to 7 Oct 2026

Spam-T5: Benchmarking Large Language Models for Few-Shot Email Spam Detection

arXiv 2304.01238 ↗First posted 3 Apr 2023cs.CL cs.AIcited by 12

Not on the map. Why?

Abstract (arXiv)

This paper investigates the effectiveness of large language models (LLMs) in email spam detection by comparing prominent models from three distinct families: BERT-like, Sentence Transformers, and Seq2Seq. Additionally, we examine well-established machine learning techniques for spam detection, such as Na"ive Bayes and LightGBM, as baseline methods. We assess the performance of these models across four public datasets, utilizing different numbers of training samples (full training set and few-shot settings). Our findings reveal that, in the majority of cases, LLMs surpass the performance of the popular baseline techniques, particularly in few-shot scenarios. This adaptability renders LLMs uniquely suited to spam detection tasks, where labeled samples are limited in number and models require frequent updates. Additionally, we introduce Spam-T5, a Flan-T5 model that has been specifically adapted and fine-tuned for the purpose of detecting email spam. Our results demonstrate that Spam-T5 surpasses baseline models and other LLMs in the majority of scenarios, particularly when there are a limited number of training samples available. Our code is publicly available at https://github.com/jpmorganchase/emailspamdetection.

Key facts. Cited by 12 papers in the map (data through 7 Oct 2026). Builds on 18 of its 52 references that are in the map. First posted on arXiv 3 Apr 2023.

Builds on

18 of 52 references.

References · 18

  1. 2017Attention Is All You Needcited by 59,932
  2. 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
  3. 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
  4. 2021LoRA: Low-Rank Adaptation of Large Language Modelscited by 14,084
  5. 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,266
  6. 2019Sentence-BERT: Sentence Embeddings using Siamese BERT-Networkscited by 9,049
  7. 2021Finetuned Language Models Are Zero-Shot Learnerscited by 3,747
  8. 2013Distributed Representations of Words and Phrases and their Compositionalitycited by 3,462
  9. 2018SentencePiece: A simple and language independent subword tokenizer and detokenizer for Neural Text Processingcited by 1,973
  10. 2016Google's Neural Machine Translation System: Bridging the Gap between Human and Machine Translationcited by 1,471
  11. 2020MPNet: Masked and Permuted Pre-training for Language Understandingcited by 973
  12. 2022LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scalecited by 881
6 more
  1. 2019Generalizing from a Few Examples: A Survey on Few-Shot Learningcited by 462
  2. 2019Text Classification Algorithms: A Surveycited by 163
  3. 2022Efficient Few-Shot Learning Without Promptscited by 135
  4. 2020A Survey on Text Classification: From Shallow to Deep Learningcited by 80
  5. 2022Universal Spam Detection using Transfer Learning of BERT Modelcited by 13
  6. 2022Spam Detection Using BERTcited by 6

Built on by

Cited by year

Citing papers per year: 2023: 1; 2024: 7; 2025: 4.

12 papers.