--- description: "Play a notification sound whenever the AI agent needs human input, confirmation, or approval" alwaysApply: true --- # Sound Notification on Human Input ## Sound commands per OS Detect the OS from user system info or `uname -s`: - **macOS**: `afplay /System/Library/Sounds/Glass.aiff &` - **Linux**: `paplay /usr/share/sounds/freedesktop/stereo/bell.oga 2>/dev/null || aplay /usr/share/sounds/freedesktop/stereo/bell.oga 2>/dev/null || echo -e '\a' &` - **Windows (PowerShell)**: `[System.Media.SystemSounds]::Exclamation.Play()` ## When to play (play exactly once per trigger) Play the sound when your turn will end in one of these states: 1. You are about to call the AskQuestion tool — sound BEFORE the AskQuestion call 2. Your text ends with a direct question to the user that cannot be answered without their input (e.g., "Which option do you prefer?", "What is the database name?", "Confirm before I push?") 3. You are reporting that you are BLOCKED and cannot continue without user input (missing credentials, conflicting requirements, external approval required) 4. You have just completed a destructive or irreversible action the user asked to review (commit, push, deploy, data migration, file deletion) ## When NOT to play - You are mid-execution and returning a progress update (the conversation is not stalling) - You are answering a purely informational or factual question and no follow-up is required - You have already played the sound once this turn for the same pause point - Your response only contains text describing what you did or found, with no question, no block, no irreversible action ## "Trivial" definition A response is trivial (no sound) when ALL of the following are true: - No explicit question to the user - No "I am blocked" report - No destructive/irreversible action that needs review If any one of those is present, the response is non-trivial — play the sound. ## Ordering The sound command is a normal Shell tool call. Place it: - **Immediately before an AskQuestion tool call** in the same message, or - **As the last Shell call of the turn** if ending with a text-based question, block report, or post-destructive-action review Do not play the sound as part of routine command execution — only at the pause points listed under "When to play".