agent: Add sound notification when done generating (#31472)

This PR adds the ability to hear a sound notification when the agent is
done generating and/or needs user input. This setting is turned off by
default and can be used together with the visual notification. The
specific sound I'm using here comes from the [Material Design 2 Sound
Library](https://m2.material.io/design/sound/sound-resources.html#).

Release Notes:

- agent: Added the ability to have a sound notification when the agent
is done generating and/or needs user input.
This commit is contained in:
Danilo Leal 2025-05-26 21:20:41 -03:00 committed by GitHub
parent fe0bcd14d2
commit d211f88d23
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 93 additions and 5 deletions

View file

@ -39,9 +39,17 @@ To follow the agent reading through your codebase and performing edits, click on
### Get Notified {#get-notified}
If you send a prompt to the Agent and then move elsewhere, thus putting Zed in the background, a notification will pop up at the top right of your screen indicating that the Agent has completed its work.
If you send a prompt to the Agent and then move elsewhere, thus putting Zed in the background, you can be notified of whether its response is finished either via:
You can customize the notification behavior, including the option to turn it off entirely, by using the `agent.notify_when_agent_waiting` settings key.
- a visual notification that appears in the top right of your screen
- or a sound notification
You can use both notification methods together or just pick one of them.
For the visual notification, you can customize its behavior, including the option to turn it off entirely, by using the `agent.notify_when_agent_waiting` settings key.
For the sound notification, turn it on or off using the `agent.play_sound_when_agent_done` settings key.
#### Sound Notification
### Reviewing Changes {#reviewing-changes}