Description
When a user sends a Discord voice message and STT is disabled (stt.enabled = false or unconfigured), the bot silently drops it — no reaction, no reply. The user thinks the bot is broken.
Root cause: Two bugs in src/discord.rs:
- Audio skip is logged at
debug!() level only — operators don't notice it in production logs.
- Voice-only messages (no text, just audio) pass the empty-check guard because
prompt_with_sender always includes the <sender_context> XML block. The agent receives a prompt with only sender context and no actual content, producing confusing or empty responses.
Prior Art
| Project |
File |
Behavior when STT unconfigured |
| OpenClaw |
audio-preflight.ts |
Transcribes before mention check; no explicit "STT off" feedback — audio is simply not processed |
| Hermes Agent |
transcription_tools.py |
Local/Groq/OpenAI fallback chain; no explicit "STT off" feedback — audio is simply not processed |
| openab (current) |
src/discord.rs |
debug!() log, silent skip, empty prompt sent to agent |
Neither OpenClaw nor Hermes Agent provides user-facing feedback when STT is unavailable. This is a gap we can fill.
Design
Approach: React with 🎤 emoji + early return for voice-only messages.
Rationale:
- Consistent with existing 🚫 pattern for denied users (react on original message, don't reply)
- Zero channel noise — no extra messages cluttering threads
- Self-explanatory: "I see your mic, but I can't do anything with it"
- Operators get
warn!() level logs for visibility
Behavior matrix:
| Message type |
STT enabled |
STT disabled |
| Voice only |
Transcribe → process |
React 🎤 → early return |
| Voice + text |
Transcribe → process all |
React 🎤 → process text only |
| Voice + image |
Transcribe → process all |
React 🎤 → process image only |
| Text only |
Process |
Process |
Files Changed
| File |
Change |
src/discord.rs |
Add warn import, track audio_skipped flag, react 🎤, early return for voice-only |
Related
Description
When a user sends a Discord voice message and STT is disabled (
stt.enabled = falseor unconfigured), the bot silently drops it — no reaction, no reply. The user thinks the bot is broken.Root cause: Two bugs in
src/discord.rs:debug!()level only — operators don't notice it in production logs.prompt_with_senderalways includes the<sender_context>XML block. The agent receives a prompt with only sender context and no actual content, producing confusing or empty responses.Prior Art
audio-preflight.tstranscription_tools.pysrc/discord.rsdebug!()log, silent skip, empty prompt sent to agentNeither OpenClaw nor Hermes Agent provides user-facing feedback when STT is unavailable. This is a gap we can fill.
Design
Approach: React with 🎤 emoji + early return for voice-only messages.
Rationale:
warn!()level logs for visibilityBehavior matrix:
Files Changed
src/discord.rswarnimport, trackaudio_skippedflag, react 🎤, early return for voice-onlyRelated