Socratic irony detector prompt
Sarcasm and irony are where literal sentiment analysis falls apart: the words say one thing and mean the opposite. “Best day ever” after a three-hour queue is mockery, not praise. The Socratic irony detector prompt builds a few-shot prompt that teaches a model to read the contextual cues — contradiction, exaggeration, scare quotes, emoji — that reveal non-literal intent, tuned to the domain you’re working in.
How it works
You pick a domain (social media, product reviews, or literature), which loads labeled examples matched to that style of irony along with an explanation of the cue each one relies on. You set the output format and a confidence threshold below which the model defaults to “sincere” rather than guessing. The tool assembles a prompt listing the contextual cues to weigh — literal-versus-situation contradiction, hyperbole, tonal markers, mock-praise, sentiment-fact mismatch — the few-shot examples, and your threshold and format. It runs locally with no API key; you paste in the text to classify.
Tips and notes
- Match the domain. Review sarcasm and literary irony look different; the wrong example set hurts accuracy.
- Raise the threshold when false positives cost you. Moderation pipelines often prefer to miss subtle sarcasm than to flag sincere praise as mockery.
- Use JSON output with a cue list. Reading why the model labeled something sarcastic is the fastest way to spot and fix misclassifications.
- Add your own examples. The domain sets are a starting point; pasting a few of your hardest real cases as extra few-shot examples lifts accuracy further.