detect_sarcasm
Analyze the mismatch between text sentiment and audio emotion to detect sarcasm in speech.
Instructions
Detect sarcasm by comparing text sentiment with audio emotion.
This tool detects sarcasm by analyzing the mismatch between the sentiment of the text and the emotional tone of the audio. For Lite tier, the 'text' parameter is required for accurate detection.
Args: audio_path: Path to the audio file (WAV format supported) text: Transcription text (recommended for Lite tier)
Returns: Dictionary containing: - is_sarcastic: Boolean indicating sarcasm detection - confidence: Confidence score (0.0 to 1.0) - indicators: List of indicators that suggest sarcasm - text_emotion: Detected emotion from text (if available) - audio_emotion: Detected emotion from audio
Example: { "is_sarcastic": true, "confidence": 0.82, "indicators": ["Positive text with negative audio tone"], "text_emotion": "positive", "audio_emotion": "sad" }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| audio_path | Yes | ||
| text | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |