TLDRocket
Sign in

SetFitABSA: Few-Shot Aspect Based Sentiment Analysis using SetFit

Hugging Face

Hugging Face and Intel Labs built SetFitABSA, a tool that spots what people liked or hated about specific product features from just a few examples. It beats Llama2 and T5 in few-shot tests while being way smaller and needing no prompts.

Based on reporting by Hugging Face — read the original for the full story.

Summary, retelling and take written by AI under human oversight; images are AI-generated illustrations. How we work · Report an error

Aspect-based sentiment analysis sounds fancy but the idea is simple: figure out not just whether a review is positive, but positive about what. "The screen is great but the battery dies fast" has two aspects and two opposite opinions. Getting a model to reliably pull that apart has usually meant either painstaking token-level labeling or leaning on giant generative models with hand-tuned prompts. Intel Labs and Hugging Face think they've found a shortcut.

SetFitABSA breaks the job into three steps. First, spaCy scans the text and grabs nouns and noun compounds as candidate aspects. Then a small SetFit classifier decides which of those candidates are actual aspects versus noise, by literally gluing the candidate word onto the full sentence and training a binary yes/no model on that pairing. A second SetFit model does the same trick to assign a sentiment label to whatever survived the first filter. No token-tagging tools, no prompt engineering, just labeled sentence pairs.

The results are the interesting part. Tested on the SemEval14 Laptop and Restaurant datasets against T5-base, GPT2-medium and Llama-2-chat, SetFitABSA held its own or won outright in low-data settings, despite using two 110-million-parameter models stacked together rather than anything close to Llama 2's 7 billion parameters. The gap was especially stark against GPT2 and T5. And oddly, throwing more in-context examples at Llama2 didn't help it catch up, echoing a quirk researchers have noticed with ChatGPT too — more examples doesn't automatically mean better few-shot performance for these generative models.

What makes this practical rather than just a benchmark flex is the training cost. The whole pipeline, both submodels, trains in about ten minutes on a free Colab T4 GPU, using something like 128 labeled examples pulled from a restaurant review dataset. You install setfit with an absa extra, grab spaCy's en_core_web_lg model, format your data as text/span/label/ordinal rows, and run a few lines through AbsaTrainer. Compared to the labeling headache of tagging every token in BIO format, just marking which spans are aspects and what sentiment they carry is a much smaller lift for anyone building a domain-specific model — say, for hotel reviews or software complaints — without a research budget.

My take — AI-written commentary, not fact-checked reporting

This is the kind of release I actually get excited about: not a bigger model, a smarter shortcut. Everyone's chasing billion-parameter generative models for tasks that a 110M-parameter classifier can nail with less data and zero prompt fiddling, and SetFitABSA is a good reminder that efficiency research still has plenty of room to embarrass the scaling-obsessed crowd. If you're a small team building something niche in Europe without GPU clusters to burn, this is the sane way to do it.

Read more about this at: Hugging Face

Related stories

The daily briefing

Every AI story that matters, in your inbox by 8am.

TLDRocket reads all relevant sources, removes duplicate coverage, and summarises the day in two minutes. Follow companies and topics for alerts, or get the briefing in Slack. Free, no spam, unsubscribe anytime.