Skip to content

Conversation

@1code-async
Copy link
Contributor

@1code-async 1code-async bot commented Jan 29, 2026

Summary

  • Add a distinct notification sound when the agent asks a question (multichoice prompt / AskUserQuestion)
  • The prompt sound is different from the completion notification sound to help users distinguish between the two
  • Sound is generated using Web Audio API with an ascending two-tone pattern (C5→E5) to feel like a question

Changes

  • src/renderer/lib/notification-sounds.ts: New utility file with playPromptSound() function using Web Audio API
  • src/renderer/lib/atoms/index.ts: Add promptSoundNotificationsEnabledAtom preference (enabled by default)
  • src/renderer/features/agents/lib/ipc-chat-transport.ts: Play prompt sound when ask-user-question chunk is received
  • src/renderer/components/dialogs/settings-tabs/agents-preferences-tab.tsx: Add "Prompt Sound" toggle in Preferences

Test plan

  • Open a workspace and start an agent that uses AskUserQuestion
  • Verify the prompt sound plays when the agent asks a question
  • Verify the sound is distinct from the completion notification
  • Toggle "Prompt Sound" off in Preferences and verify no sound plays on prompts
  • Verify the existing completion sound still works as before

🤖 Generated with Claude Code

Play a different sound when the agent asks a question (AskUserQuestion)
to distinguish it from the completion notification:

- Add new promptSoundNotificationsEnabledAtom preference (enabled by default)
- Create notification-sounds.ts utility with Web Audio API for distinct tone
- Trigger prompt sound in ipc-chat-transport when questions are received
- Add "Prompt Sound" toggle in Preferences settings

The prompt sound uses an ascending two-tone pattern (C5→E5) to feel
like a question, while the existing completion sound remains unchanged.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant