Use cases

How to tag customer feedback against your own taxonomy

Off-the-shelf topic and sentiment models tag feedback in someone else's categories. The useful tags are yours, and they change every time the product does.

The pain points

How to do it

  1. Write each tag as a definition with boundary examples: one clear case, one near-miss that belongs to a neighbour tag. That document is the first draft of the prompt.
  2. Double-label a sample and measure agreement per tag. A tag your analysts cannot agree on needs a better definition before it needs a model. Fix the definitions first; it is the cheapest improvement you will make.
  3. Output a list, score every tag. Precision and recall per tag, macro-averaged so a rare tag counts as much as a common one. Put that average in the objective, not exact match on the whole list.
  4. Optimize, then read the per-tag table and the diff. The useful rewrites sharpen the definition of a tag that was being confused with a neighbour. Check that is what changed.
  5. Version the taxonomy with the prompt. When a tag is added or split, relabel a sample under the new definitions and re-run against that, instead of mixing old and new labels.

Pitfalls worth checking first

PitfallWhat it looks likeHow to check, before spending anything
Frequent tags dominateOverall scores rise while rare tags go unfoundMacro-average per-tag recall; read the rare tags on their own.
Agreement ceilingScores plateau well short of perfectCompare against how often your analysts agree. That is roughly the ceiling.
"Other" as a crutchA growing share lands in a catch-all tagRead a sample of "other". It is usually a missing tag or a vague definition.
Mixed taxonomiesThe same comment carries old and new tagsRelabel under one version of the taxonomy before scoring.
Sentiment bleedNegative comments get tagged as problemsKeep sentiment a separate field from topic.

References

Tools that run this loop: DSPy and its GEPA optimizer, bpto (ours, open source), and Impromptune, the studio built on it.