agent: Remove last turn after a refusal (#31220)

This is a follow-up to https://github.com/zed-industries/zed/pull/31217
that removes the last turn after we get a `refusal` stop reason, as
advised by the Anthropic docs.

Meant to include it in that PR, but accidentally merged it before
pushing these changes 🤦🏻‍♂️.

Release Notes:

- N/A
ceb5164114Marshall Bowers committed on 5/22/2025, 9:38:33 PM· committed by GitHubparent24a108d
1 file changedLine totals unavailable