# agent_ui: Queue prompts by default when sending them while generating \(\#46797\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/9621fac835267a7ccd82fefcb3925b1136f4eca5)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 9621fac835267a7ccd82fefcb3925b1136f4eca5

Requested commit: 9621fac835267a7ccd82fefcb3925b1136f4eca5

Commit: 9621fac835267a7ccd82fefcb3925b1136f4eca5

Tree: 47b77c2e4cc74c83f77a6bbfacbd5ad4ab341dc6

Author: Danilo Leal

Committer: GitHub

## Message

```
agent_ui: Queue prompts by default when sending them while generating (#46797)

This PR makes queueing a prompt the default behavior when sending a new
one while there's an on-going generation. You can still send a prompt
that will immediately interrupt the agent with the `cmd-shift-enter`
keybinding, though, which preserves the current behavior.

The main motivation for this change is to make the queueing not only
more discoverable, but more useful as well, as we're parting from the
assumption that most of the time, what you want is to queue it as
opposed to interrupting it (even though it's still possible to do either
through the keybinding I mentioned above or simply by stopping the
generation and sending a new one).

Here's a quick video:


https://github.com/user-attachments/assets/37f92433-70ef-459f-98ff-41ed80e3e43f

In the video, I show sending one prompt and then sending two others that
fall straight into the queue. Then, in the middle of the generation of
my first prompt, I use the `cmd-shift-enter` keybinding to send a prompt
immediately, interrupting the agent, effectively being sent in front of
the queue.

Release Notes:

- Agent: Made queueing prompts the default behavior when sending them
while there's an on-going generation.
```

## Parents

- [9e44d92a016672dff2f7bfdd51f58492478bacc8](https://git.cafe/gitcafe/zed/commit/9e44d92a016672dff2f7bfdd51f58492478bacc8?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/9621fac835267a7ccd82fefcb3925b1136f4eca5?format=markdown)
