---
title: "How Hugging Face Accelerated Development of Witty Works Writing Assistant"
description: "Witty Works' inclusive-language writing assistant began with spaCy-based linguistic feature matching, which handled about 85% of its ~2,300-word vocabulary but failed on context-dependent words like \"fossil\" or \"flexible.\" On Hugging Face experts' advice, the team switched from contextualized word embeddings to Sentence Transformers sentence embeddings and used SetFit few-shot fine-tuning, feeding mpnet-base-v2 embeddings into logistic regression and KNN classifiers."
url: "https://swe.quest/articles/how-hugging-face-accelerated-development-of-witty-works-writing-assistant-c724e5be1af64d53"
canonical: "https://huggingface.co/blog/classification-use-cases"
source: "Hugging Face"
published: "2023-03-01"
difficulty: "easy"
kind: "Case study"
reading_minutes: 6
tags: ["machine-learning","model-training","llms"]
---

# How Hugging Face Accelerated Development of Witty Works Writing Assistant

A post on [Hugging Face](https://swe.quest/sources/hugging-face.md), published 2023-03-01, 6 min read, Case study. Original: [https://huggingface.co/blog/classification-use-cases](https://huggingface.co/blog/classification-use-cases)

## Summary

Witty Works' inclusive-language writing assistant began with spaCy-based linguistic feature matching, which handled about 85% of its ~2,300-word vocabulary but failed on context-dependent words like "fossil" or "flexible." On Hugging Face experts' advice, the team switched from contextualized word embeddings to Sentence Transformers sentence embeddings and used SetFit few-shot fine-tuning, feeding mpnet-base-v2 embeddings into logistic regression and KNN classifiers. Labeled data needs dropped from 100-200 to 15-20 sentences per word, and the model reached 0.92 accuracy. It was deployed on Azure without further optimization because latency was already acceptable.

Written by swe.quest, not by the author.

**Difficulty:** Easy: no special background needed; explains what something is and why it matters

## Topics

- [Machine learning](https://swe.quest/tags/machine-learning.md) (AI & ML)
- [Model training](https://swe.quest/tags/model-training.md) (AI & ML)
- [LLMs](https://swe.quest/tags/llms.md) (AI & ML)

## Prerequisites

- sentence embeddings ([easy posts on RAG & retrieval](https://swe.quest/tags/rag.md?difficulty=easy))
- text classification basics

## Keywords

SetFit, Sentence Transformers, mpnet-base-v2, spaCy, Hugging Face, Azure, Witty Works

## Related posts

- [Fine-Tune Wav2Vec2 for English ASR in Hugging Face with 🤗 Transformers](https://swe.quest/articles/fine-tune-wav2vec2-for-english-asr-in-hugging-face-with-transformers-3965ec4df26fb19a.md): Hugging Face · 2021-03-12 · Medium · 24 min read · Speech & audio, Model training, Python
  Wav2Vec2, pretrained with a contrastive masked objective on 50k+ hours of unlabeled speech, can be fine-tuned with CTC on small labeled datasets for end-to-end English ASR without a language model.
- [SetFit: Efficient Few-Shot Learning Without Prompts](https://swe.quest/articles/setfit-efficient-few-shot-learning-without-prompts-aff1dcaa7c0b808d.md): Hugging Face · 2022-09-26 · Medium · 6 min read · Model training, Machine learning, Python
  SetFit is a prompt-free few-shot text classification framework that first fine-tunes a Sentence Transformer contrastively on in-class/out-of-class sentence pairs built from a handful of labeled examples, then trains a classifier head on the resulting embeddings.
- [Blazingly fast whisper transcriptions with Inference Endpoints](https://swe.quest/articles/blazingly-fast-whisper-transcriptions-with-inference-endpoints-d93b7d262c3a1210.md): Hugging Face · 2025-05-13 · Easy · 6 min read · Inference & serving, Speech & audio, Performance engineering
  Hugging Face Inference Endpoints now offers a Whisper deployment built on vLLM that delivers up to roughly 8x higher real-time factor (RTFx) than the Transformers implementation, with comparable word error rate.
- [SetFitABSA: Few-Shot Aspect Based Sentiment Analysis using SetFit](https://swe.quest/articles/setfitabsa-few-shot-aspect-based-sentiment-analysis-using-setfit-1531f1fb3bd2dc96.md): Hugging Face · 2023-12-06 · Medium · 9 min read · Machine learning, Model training, Python
  SetFitABSA performs few-shot aspect-based sentiment analysis in three stages: spaCy extracts noun and noun-compound aspect candidates, one SetFit model classifies each candidate as aspect or non-aspect, and a second SetFit model assigns a sentiment polarity to each aspect.
- [Training and Finetuning Embedding Models with Sentence Transformers](https://swe.quest/articles/training-and-finetuning-embedding-models-with-sentence-transformers-d6dcb3eebe384143.md): Hugging Face · 2024-05-28 · Medium · 14 min read · Model training, Python, Machine learning, Search, Evaluation
  Sentence Transformers v3 trains and finetunes embedding models through a SentenceTransformerTrainer that combines Hugging Face datasets, a loss function, optional training arguments and evaluators.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
