Commit log

e204b37 Bump to 0.184.10 for @maxdeviant

Zed Bot created

1725985 language_models: Pass up `mode` from the `LanguageModelRequest` (cherry-pick #29552) (#29890)

Click to expand commit body
Cherry-picked language_models: Pass up `mode` from the
`LanguageModelRequest` (#29552)

This PR makes it so we pass up the `mode` from the
`LanguageModelRequest` when interacting with the Zed provider instead of
passing a hard-coded value.

Release Notes:

- agent: Fixed an issue where max mode was always being used.

Co-authored-by: Marshall Bowers <git@maxdeviant.com>

gcp-cherry-pick-bot[bot] and Marshall Bowers created

12a274b zed 0.184.9

Joseph T. Lyons created

6bc494c Properly score fuzzy match queries with multiple chars in lower case (cherry-pick #29794) (#29797)

Click to expand commit body
Cherry-picked Properly score fuzzy match queries with multiple chars in
lower case (#29794)

Closes https://github.com/zed-industries/zed/issues/29526

Release Notes:

- Fixed file finder crashing for certain file names with multiple chars
in lowercase form

Co-authored-by: Kirill Bulatov <kirill@zed.dev>

gcp-cherry-pick-bot[bot] and Kirill Bulatov created

3c0a8da Fix tasks not being stopped on reruns (#29786)

Click to expand commit body
Follow-up of https://github.com/zed-industries/zed/pull/28993

* Tone down tasks' cancellation logging
* Fix task terminals' leak, disallowing to fully cancel the task by
dropping the terminal off the pane:

https://github.com/zed-industries/zed/blob/f619d5f02af100c34e286af294a42a01dcfb238c/crates/terminal_view/src/terminal_panel.rs#L1464-L1471

Release Notes:

- Fixed tasks not being stopped on reruns

Kirill Bulatov created

b64161d v0.184.x stable

Joseph T. Lyons created

49bc7a7 editor: Improve code completions by prioritizing prefix matching (#29456)

Click to expand commit body
- Use common prefix length-based matching as primary criteria.
- Test added for multiple cases.

Before:
<img width="500" alt="image"
src="https://github.com/user-attachments/assets/8c653225-cac2-41bd-95f0-0fb8724284c9"
/>

After:
<img width="500" alt="image"
src="https://github.com/user-attachments/assets/a3d59399-cff2-435d-9b56-69a530f35da4"
/>

Release Notes:

- Fixed issues with code completions where they wouldn't show
completions with matched prefix at top.

Smit Barmase created

0ca114e python: Do not look up venv path from source file path (#29676)

Click to expand commit body
Closes #ISSUE

Release Notes:

- N/A

Piotr Osiewicz created

dee476b Bump to 0.184.8 for @osiewicz

Zed Bot created

be439e9 Revert "python: Enable subroot detection for pylsp and pyright (#27364)" (cherry-pick #29658) (#29661)

Click to expand commit body
Cherry-picked Revert "python: Enable subroot detection for pylsp and
pyright (#27364)" (#29658)

This reverts commit e661a0afd64e3e6e1e51c981cb7bda4e0af724fd.

Closes #ISSUE

Release Notes:

- Reverted changes to Python subroot detection which could have caused
multiple python processes to be spawned when working in projects with
multiple `pyproject.toml` files.

Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>

gcp-cherry-pick-bot[bot] and Piotr Osiewicz created

7609894 Maybe fix panic (#29352)

Click to expand commit body
Since around the time we shipped block diagnostics, we've been seeing an
out of range panic in the editor.

Although the code is heavily inlined, so the stacktrace is missing, this
seems like a likely place that indexing may have gone wrong.

Release Notes:

- Fixed a rare panic in the editor

Conrad Irwin created

92d6ee1 zed 0.184.7

Joseph T. Lyons created

6b221fb Derive Default for TaskId and SpawnInTerminal

Click to expand commit body
These were made Default in #29208, but rather than pull that entire commit in to fix this, I'm resolving manually.

Joseph T. Lyons created

6406105 agent: Add icon for Zed's max mode (#29610)

Click to expand commit body
Release Notes:

- N/A

Danilo Leal created

9bd7dcb agent: Enrich `grep` tool output with syntax information (#29601)

Click to expand commit body
The `grep` tool used to include 4 lines of context around the match, but
the lines included would often be unhelpful. This PR improves this
behavior by using the range of the parent syntax node that contains the
full line(s) matched.

The match headers will also now include symbol breadcrumbs so that the
model can already gather code structure before/without reading files.

````md
### impl GitRepository for RealGitRepository β€Ί fn compare_checkpoints β€Ί L1278-1284
```rust
                let result = git
                    .run(&[
                        "diff-tree",
                        "--quiet",
                        &left.commit_sha.to_string(),
                        &right.commit_sha.to_string(),
                    ])
```
````

This positively impacts the `add_arg_to_trait_method` eval example with
better diff output, fewer tool failures, and reduced total turns.

Note: We have some plans to use a an "elision" approach where we would
combine all matches for a given file, skipping lines between them while
keeping symbol declaration lines. The theory is that this would be map
more closely to the expected input for edits. For now, this PR is a
significant improvement.

Release Notes:

- Agent: Enrich `grep` tool output with syntax information

Agus Zubiaga created

597eb8f bedrock: Preserve thinking blocks for Bedrock (#29602)

Click to expand commit body
Fixes a regression from #29055, resolves #29290

Release Notes:

- agent: Fixed a regression that rendered Claude 3.7 Thinking unusable
on Bedrock.

Shardul Vaidya created

c14313e agent: Create `TerminalToolCard` and display shell output while it's running (#29546)

Click to expand commit body
Also, don't require a worktree to run the terminal tool.

Release Notes:

- N/A

JoΓ£o Marcos created

1bc14b7 language_models: Change default fast model for Zed provider (#29600)

Click to expand commit body
This PR changes the default fast model for the Zed provider from Claude
3.5 Haiku to Claude 3.5 Sonnet.

We don't offer Claude 3.5 Haiku to users.

Closes https://github.com/zed-industries/zed/issues/29505.

Release Notes:

- agent: Changed the default fast model for the Zed provider to Claude
3.5 Sonnet.

Marshall Bowers created

a108c68 Re-add code block formatting instructions (#29574)

Click to expand commit body
Re-enabled instructions about code block formatting.

In practice, the model doesn't seem to use these very often, but there's
no negative effect on evals. In a future PR, I'll experiment with adding
more evals around the model actually using the code blocks.

2 runs before: (`--repetitions=8`)
```
=================================================================
                            AGGREGATE
=================================================================


4 examples failed to run!
Average programmatic score: 37%
Average diff score: 66%
Average thread score: 93%


-----------------------------------------------------------------
                     CUMULATIVE TOOL METRICS
-----------------------------------------------------------------

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚             Tool             β”‚   Uses   β”‚ Failures β”‚   Rate   β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚edit_file                     β”‚   398    β”‚    53    β”‚   13%    β”‚
β”‚terminal                      β”‚    11    β”‚    1     β”‚    9%    β”‚
β”‚create_file                   β”‚    40    β”‚    2     β”‚    5%    β”‚
β”‚read_file                     β”‚   245    β”‚    8     β”‚    3%    β”‚
β”‚find_path                     β”‚    48    β”‚    0     β”‚    0%    β”‚
β”‚list_directory                β”‚    13    β”‚    0     β”‚    0%    β”‚
β”‚grep                          β”‚   133    β”‚    0     β”‚    0%    β”‚
β”‚thinking                      β”‚    18    β”‚    0     β”‚    0%    β”‚
β”‚diagnostics                   β”‚   130    β”‚    0     β”‚    0%    β”‚
```

```
=================================================================
                            AGGREGATE
=================================================================


1 examples failed to run!
Average programmatic score: 41%
Average diff score: 68%
Average thread score: 96%


-----------------------------------------------------------------
                     CUMULATIVE TOOL METRICS
-----------------------------------------------------------------

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚             Tool             β”‚   Uses   β”‚ Failures β”‚   Rate   β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚fetch                         β”‚    1     β”‚    1     β”‚   100%   β”‚
β”‚edit_file                     β”‚   553    β”‚    63    β”‚   11%    β”‚
β”‚read_file                     β”‚   349    β”‚    3     β”‚    1%    β”‚
β”‚diagnostics                   β”‚   158    β”‚    0     β”‚    0%    β”‚
β”‚find_path                     β”‚    70    β”‚    0     β”‚    0%    β”‚
β”‚list_directory                β”‚    10    β”‚    0     β”‚    0%    β”‚
β”‚thinking                      β”‚    45    β”‚    0     β”‚    0%    β”‚
β”‚grep                          β”‚   213    β”‚    0     β”‚    0%    β”‚
β”‚create_file                   β”‚    24    β”‚    0     β”‚    0%    β”‚
β”‚terminal                      β”‚    17    β”‚    0     β”‚    0%    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
```

1 run after this change:

```
=================================================================
                            AGGREGATE
=================================================================

Average programmatic score: 42%
Average diff score: 74%
Average thread score: 100%


-----------------------------------------------------------------
                     CUMULATIVE TOOL METRICS
-----------------------------------------------------------------

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚             Tool             β”‚   Uses   β”‚ Failures β”‚   Rate   β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚edit_file                     β”‚   534    β”‚    92    β”‚   17%    β”‚
β”‚read_file                     β”‚   325    β”‚    6     β”‚    2%    β”‚
β”‚list_directory                β”‚    6     β”‚    0     β”‚    0%    β”‚
β”‚thinking                      β”‚    12    β”‚    0     β”‚    0%    β”‚
β”‚create_file                   β”‚    16    β”‚    0     β”‚    0%    β”‚
β”‚diagnostics                   β”‚    49    β”‚    0     β”‚    0%    β”‚
β”‚grep                          β”‚   234    β”‚    0     β”‚    0%    β”‚
β”‚find_path                     β”‚    65    β”‚    0     β”‚    0%    β”‚
β”‚terminal                      β”‚    38    β”‚    0     β”‚    0%    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
```


Release Notes:

- N/A

Richard Feldman created

a211571 agent: Support images via @file and the file context picker (#29596)

Click to expand commit body
Release Notes:

- agent: Add support for @mentioning images
- agent: Add support for including images via file context picker

---------

Co-authored-by: Oleksiy Syvokon <oleksiy.syvokon@gmail.com>

Bennet Bo Fenner and Oleksiy Syvokon created

747471c zed 0.184.6

Joseph T. Lyons created

8acd8a2 Fix gemini model token limits (#29584)

Click to expand commit body
Release Notes:

- N/A

Michael Sloan created

13854b4 agent: Improve MCP tools compatibility with Gemini models (#29411)

Click to expand commit body
Release Notes:

- agent: Improve MCP tools compatibility with Gemini models

Bennet Bo Fenner created

f50dc72 Fix context_stack race in KeyContextView (#29324)

Click to expand commit body
cc @notpeter

Before this change we used our own copy of `cx.key_context()` when
matching.
This led to races where the context queried could be either before (or
after) the
context used in dispatching.

To avoid the race, gpui now passes out the context stack actually used
instead.

Release Notes:

- Fixed a bug where the Key Context View could show the incorrect
context,
  causing confusing results.

Conrad Irwin created

9e03eac ollama: Add Qwen3 and Gemma3 (default to 16K context) (#29580)

Click to expand commit body
If you have the VRAM you can increase the context by adding this to your
settings.json:

```json
  "language_models": {
    "ollama": {
      "available_models": [
        { "max_tokens": 65536, "name": "qwen3", "display_name": "Qwen3-64k" }
      ]
    }
  },
```

Release Notes:

- ollama: Add support for Qwen3. Defaults to 16K token context. See:
[Assistant Configuration
Docs](https://zed.dev/docs/assistant/configuration#ollama-context) to
increase.

Peter Tripp created

34bb705 ollama: Add DeepSeek v3 max token length (#29156)

Click to expand commit body
Add deepseek-v3 max token length for ollama

Release Notes:

- N/A

shenjack created

b2d49fb Refactor markdown formatting utilities to avoid building intermediate strings (#29511)

Click to expand commit body
These were nearly always used when using `format!` / `write!` etc, so it
makes sense to not have an intermediate `String`.

Release Notes:

- N/A

Michael Sloan created

5721089 Fix agent rules files for remote project by loading via buffer (#29440)

Click to expand commit body
When using the agent with a project shared by a collaborator, rules file
loading didn't work as it was trying to read from the client's
filesystem

Release Notes:

- Fixed rules file loading when using the agent with a project shared by
a collaborator.

Michael Sloan created

39483b3 title_bar: Put plan behind `new-billing` feature flag (#29540)

Click to expand commit body
This PR puts the displaying of the plan in the user menu behind the
`new-billing` feature flag instead of the old `zed-pro` feature flag.

Release Notes:

- N/A

Marshall Bowers created

aff5ac5 feature_flags: Add `FeatureFlag` suffix to feature flag types (#29392)

Click to expand commit body
This PR adds the `FeatureFlag` suffix to the feature flag types that
were missing them.

This makes the names easier to search in the codebase.

Release Notes:

- N/A

Marshall Bowers created

bf915e9 feature_flags: Remove `remoting` feature flag (#29390)

Click to expand commit body
This PR removes the `remoting` feature flag.

The feature is shipped, and we aren't referencing the flag anywhere
anymore.

Release Notes:

- N/A

Marshall Bowers created

cc8fe25 Agent: Include partial output if terminal tool fails (#29115)

Click to expand commit body
This PR addresses the behavior of the agent's terminal tool when the
executed command is interrupted or fails after producing some output.
Currently, if the command doesn't finish successfully, any partial
output captured before the interruption/failure is discarded, and only
an error message (or a generic cancellation message) is returned to the
LLM.

This change modifies the `run_command_limited` function in the terminal
tool to catch errors when awaiting the command's status (which includes
interruptions). In the case of such an error, it now includes any
partial stdout/stderr captured up to that point within the error message
returned to the `ToolUseState`. This ensures the LLM receives the
partial context even when the command doesn't complete cleanly, framed
appropriately as part of an error/interruption message.

Closes #29101

Release Notes:

- N/A

Mani Rash Ahmadi created

6476700 language_models: Count Google AI tokens through LLM service (#29319)

Click to expand commit body
This PR wires the counting of Google AI tokens back up.

It now goes through the LLM service instead of collab's RPC.

Still only available for Zed staff.

Release Notes:

- N/A

Marshall Bowers created

0a656c2 language_models: Pass up `mode` for completion requests through Zed (#29294)

Click to expand commit body
This PR makes it so we pass up the `mode` for completion requests
through the Zed provider.

Release Notes:

- N/A

Marshall Bowers created

93cf95f collab: Remove `CountLanguageModelTokens` RPC message (#29314)

Click to expand commit body
This PR removes the `CountLanguageModelTokens` RPC message from collab.

We were only using this for Google AI models through the Zed provider
(which is only available to Zed staff).

For now we're returning `0`, but will bring back soon.

Release Notes:

- N/A

Marshall Bowers created

8a68fad collab: Remove code for embeddings (#29310)

Click to expand commit body
This PR removes the embeddings-related code from collab and the
protocol, as we weren't using it anywhere.

Release Notes:

- N/A

Marshall Bowers created

b39f9e9 agent: Include grep-related instructions in the prompt only if the tool is available (#29536)

Click to expand commit body
This change updates the system prompt to conditionally include
`grep`-related instructions based on whether the `grep` tool is enabled.

Implementation details:
1. Add a `has_tool` handlebars helper.
2. Pass the `model` to all locations where the prompt is built.
3. Use `{{#if has_tool "grep"}}` in the system prompt to gate
`grep`-specific instructions.

Testing:
- Unit tests for the `hasTool` helper.
- Unit tests to verify that `grep`-related instructions are included /
omitted from the prompt as appropriate.
- Manual agent evaluation:
- Setup: Asked the Agent "List all impls of MyTrait in the project"
using a custom "No tools" profile (all tools disabled).
- Before the change: The Agent attempted to call `grep`, encountered an
error, then realized the tool was unavailable.
- After the change: The Agent immediately asked to enable a search tool.

Note: in principle, `grep`/`read_file` tool descriptions alone might be
enough, but to confirm this we need more evaluation. If it turns out to
be true, we'll be able to remove grep-specific instructions from the
system prompt and undo this change.

Release Notes:

- N/A

Oleksiy Syvokon created

7eeed54 agent: Add "max mode" toggle (#29549)

Click to expand commit body
This PR adds a "max mode" toggle to the Agent panel, for models that
support it.

Only visible to folks in the `new-billing` feature flag.

Icon is just a placeholder.

Release Notes:

- N/A

Marshall Bowers created

af292ed agent: Improve attached context display and show hovers for symbol / selection / rules / thread (#29551)

Click to expand commit body
* Brings back hover popover of selection context.

* Adds hover popover for symbol, rules, and thread context.

* Makes context attached to messages display the names / content at
attachment time.

* Adds the file name as the displayed parent of symbol context.

* Brings back `impl Component for AddedContext`

Release Notes:

- N/A

---------

Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>

Michael Sloan and Bennet Bo Fenner created

b1aa15f Use `u64` instead of `usize` in `ElementId` (#29493)

Click to expand commit body
Truncation to a 32 bit `usize` could cause two distinct IDs to be
considered the same element.

Release Notes:

- N/A

Michael Sloan created

2bfac79 zed 0.184.5

Joseph T. Lyons created

a62a6c4 askpass: Shell escape Zed path in askpass script (cherry-pick #29447) (#29449)

Click to expand commit body
Cherry-picked askpass: Shell escape Zed path in askpass script (#29447)

Closes #29439

Add shell escaping as well as additional sanity check for Zed path when
used in askpass. This caused issues on preview and nightly as the
standard paths for those releases contain spaces which were not escaped
appropriately leading to erroneous "Permission denied" errors from SSH
when the askpass script failed

Release Notes:

- Fixed a missing shell-escape in askpass resulting in erroneous
"Permission denied" errors when trying to connect to a remote server
over ssh (effecting preview release v0.184.1 and nightly only)

Co-authored-by: Ben Kunkle <ben@zed.dev>

gcp-cherry-pick-bot[bot] and Ben Kunkle created

d68df74 agent: Simplify elements of the thread design (#29533)

Click to expand commit body
Namely, this PR removes the layout shift when you click on a user
message to edit it and displays the feedback disclaimer only upon
hovering the thumbs up/down button container.

Release Notes:

- N/A

Danilo Leal created

17e2746 agent: Bring title editing back to text threads (#29425)

Click to expand commit body
This also fixes a little UI bug where the text thread title would push
the buttons away from the UI when there was still space.

Release Notes:

- agent: Made text thread titles editable again.

---------

Co-authored-by: Michael Sloan <mgsloan@gmail.com>

Danilo Leal and Michael Sloan created

45ebaac agent tools: Make `read_file.end_line` inclusive (#29524)

Click to expand commit body
One motivation is that the outlines returned by `read_file` for large
files list line numbers assuming an inclusive `end_line`. As a result,
when the agent uses these outlines for `read_line` calls, it would
otherwise miss the last line.

Release Notes:

- N/A

Oleksiy Syvokon created

0f051dd Fix error when deserializing Gemini streams (#29470)

Click to expand commit body
Sometimes Gemini would report `Content` without a `parts` field.

Release Notes:

- Fixed a bug that would sometimes cause Gemini models to fail streaming
their response.

Antonio Scandurra created

18c2137 zed 0.184.4

Joseph T. Lyons created

d92de5e editor: Improve fuzzy match bucket logic for code completions (#29442)

Click to expand commit body
Add new test and improve fuzzy match bucket logic which results into far
better balance between LSP and fuzzy search.

Before:
<img width="500" alt="before"
src="https://github.com/user-attachments/assets/3e8900a6-c0ff-4f37-b88e-b0e3783b7e9a"
/>

After:
<img width="500" alt="after"
src="https://github.com/user-attachments/assets/738c074c-d446-4697-aac6-9814362e88db"
/>

Release Notes:

- N/A

Smit Barmase created

0078f67 editor: Add setting for snippet sorting behavior for code completion (#29429)

Click to expand commit body
Added `snippet_sort_order`, which determines how snippets are sorted
relative to other completion items. It can have the values `top`,
`bottom`, or `inline`, with `inline` being the default.

This mimics VS Code’s setting:
https://code.visualstudio.com/docs/editing/intellisense#_snippets-in-suggestions

Release Notes:

- Added support for `snippet_sort_order` to control snippet sorting
behavior in code completion menus.

Smit Barmase created

77f1609 ui: Add `inline_code` method to label (#29306)

Click to expand commit body
This makes it easy to have a label that looks like Markdown inline code
via the `inline_code(cx)` method.

Release Notes:

- N/A

Danilo Leal created