Commit Graph
143 Commits
Author SHA1 Message Date
Max Brunsfeld bebf3dca6c Add edit prediction evals that test related excerpt usage (#50256)
I've also fixed a race condition with the programmatic context retrieval
in the CLI, which was causing no excerpts to be fetched for the Rust
examples.

Release Notes:

- N/A
2026-02-26 15:36:29 -08:00
Tom Houlé 881d167340 Add fast mode toggle in agent panel (#49714)
This is a staff only toggle for now, since the consequences of
activating it are not obvious and quite dire (tokens costs 6 times
more).

Also, persist thinking, thinking effort and fast mode in DbThread so the
thinking mode toggle and thinking effort are persisted.

Release Notes:

- Agent: The thinking mode toggle and thinking effort are now persisted
when selecting a thread from history.
2026-02-26 21:19:41 +01:00
Max Brunsfeld 0da25d609d Edit prediction: add some typescript evals, fix a teacher model failure mode (#50141)
In some evals, the teacher produced hallucinations, seemingly due to
context rot. This makes the zeta prompt crate's budgeted rendering
usable by the teacher, so that it can truncate the list of excerpts.

I've also cleaned up the implementation of zeta_prompt's
`format_related_files_within_budget`, and changed the behavior so that
it filters the the excerpts by priority but renders the files in their
original order.

Release Notes:

- N/A
2026-02-25 15:47:08 -08:00
Oleksiy Syvokon 94030352ab ep: Stratify by cursor_path by default (#50111)
Also, `ep split train=100` now means 100 lines, not 100 groups (repos or
cursor_paths).


Release Notes:

- N/A
2026-02-25 18:15:05 +00:00
Max Brunsfeld 4f59c67cd7 Fix incorrect cursor excerpt handling in EP CLI format-prompt (#49947)
Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-02-24 05:13:33 +00:00
Max BrunsfeldandBen Kunkle a98e4651a2 Fix handling of excerpt regions in EP CLI (#49936)
Previously, we were not computing excerpt regions correctly for EP
examples captured from prod. This PR fixes that, and also simplifies the
data flow in the EP CLI. Examples either come from a concise spec (like
the markdown evals), or are collected from prod. Either way, we compute
from them a `ZetaPromptInput`, and the downstream steps like
prompt-formatting and scoring are derived from that.

Release Notes:

- N/A

---------

Co-authored-by: Ben Kunkle <ben@zed.dev>
2026-02-23 17:08:09 -08:00
384e0c45e7 zeta: Consolidate logic for picking region sizes, use larger editable region (#49921)
This will not affect how Zeta 2 behaves in production until we update
Cloud to pull in the changes to the `zeta_prompt` crate. But from some
early testing, it seems to improve behavior, not worsen it, even though
the editable region size differs from the currently-deployed model's
training data.

Release Notes:

- N/A

---------

Co-authored-by: Oleksiy Syvokon <oleksiy.syvokon@gmail.com>
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Zed Zippy <234243425+zed-zippy[bot]@users.noreply.github.com>
2026-02-23 12:52:33 -08:00
Oleksiy Syvokon c369192562 ep: Add a parameter to sample at most N near-duplicates (#49870)
Duplicates are defined as cursor positions that have an approximate
Jaccard similarity greater than 0.5 (over token 5-grams).

From the resulting clusters of near-duplicates, we select up to N
examples that are maximally different from each other.


Release Notes:

- N/A
2026-02-23 10:56:57 +00:00
Oleksiy Syvokon 629e7708cc ep: Fix teacher parser and other fixes (#49863)
Release Notes:

- N/A
2026-02-23 07:18:04 +00:00
Ben Kunkle 411c791bb2 ep_cli: Only compute reversals on last user edit (#49747)
Closes #ISSUE

Before you mark this PR as ready for review, make sure that you have:
- [ ] Added a solid test coverage and/or screenshots from doing manual
testing
- [ ] Done a self-review taking into account security and performance
aspects
- [ ] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-02-20 16:25:40 -05:00
Ben Kunkle 5d8f387863 ep_cli: Delete sync-deployments command (#49728)
Closes #ISSUE

Before you mark this PR as ready for review, make sure that you have:
- [ ] Added a solid test coverage and/or screenshots from doing manual
testing
- [ ] Done a self-review taking into account security and performance
aspects
- [ ] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-02-20 16:14:04 +00:00
Ben Kunkle eefb6ecebd ep_cli: Don't filter rated predictions by Zed version (#49609)
Closes #ISSUE

Before you mark this PR as ready for review, make sure that you have:
- [ ] Added a solid test coverage and/or screenshots from doing manual
testing
- [ ] Done a self-review taking into account security and performance
aspects
- [ ] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-02-19 22:23:24 -05:00
d249200765 Allow using Zeta through an arbitrary OpenAI-compatible self-hosted API (#49554)
Release Notes:

- Added the ability to use a self-hosted OpenAI-compatible server for
edit predictions.

---------

Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Zed Zippy <234243425+zed-zippy[bot]@users.noreply.github.com>
2026-02-19 20:18:36 +00:00
Piotr OsiewiczandEric Holk dc4bba93ef gpui: Extract gpui_platform out of gpui (#49277)
#2874 on steroids

Before you mark this PR as ready for review, make sure that you have:
- [ ] Added a solid test coverage and/or screenshots from doing manual
testing
- [ ] Done a self-review taking into account security and performance
aspects
- [ ] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)

Release Notes:

- N/A

---------

Co-authored-by: Eric Holk <eric@zed.dev>
2026-02-19 18:57:49 +01:00
Oleksiy Syvokon e823587585 ep: Fix pull examples query (#49610)
Release Notes:

- N/A
2026-02-19 15:09:03 +00:00
Oleksiy Syvokon 8ef2b9b06e ep: Parse "user accepted prediction" markers in evals (#49598)
Also:
- Add two evals
- Remove duplicated Example 6 from the teacher prompt 

Release Notes:

- N/A
2026-02-19 13:01:07 +00:00
Ben Kunkle 912f600a7b ep_cli: Filter fetched examples by can_collect_data (#49506)
Closes #ISSUE

Before you mark this PR as ready for review, make sure that you have:
- [ ] Added a solid test coverage and/or screenshots from doing manual
testing
- [ ] Done a self-review taking into account security and performance
aspects
- [ ] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-02-18 12:27:04 -05:00
Oleksiy Syvokon a1ddc50bac ep: Update teacher prompt (#49489)
* More conservative predictions for prose
* Explain "user accepted prediction" in the teacher prompt
* Sonnet 4.6 support
* Don't strip comments in teacher prompt's edit history

Release Notes:

- N/A
2026-02-18 15:26:47 +00:00
Oleksiy Syvokon a3d5f56be8 ep: Encode cursor position in the predicted patch (#49450)
Release Notes:

- N/A
2026-02-18 09:55:26 +00:00
Max Brunsfeld 301a892885 Put back logic for passing data collection choice to cloud (#49426)
Release Notes:

- N/A
2026-02-17 17:43:40 -08:00
Max Brunsfeld 4315ed2ca1 Filter collection of snowflake requests to those with latest schemas (#49424)
This allows us to just pull requests that have the latest EP request
schema with the `predicted` boolean on events in the edit history.

Release Notes:

- N/A
2026-02-17 16:37:28 -08:00
Max Brunsfeld 7fd3dd4bf7 Remove project cache in edit prediction CLI (#49409)
The cache isn't needed, now that we have a better way of reducing
resource consumption (disabling worktree scanning), and it adds race
conditions.

Release Notes:

- N/A
2026-02-17 14:20:46 -08:00
Oleksiy Syvokon 060715704d ep: Fix Unicode chars boundary (#49351)
Release Notes:

- N/A
2026-02-17 11:39:51 +00:00
Oleksiy Syvokon c37f0d3af0 ep: Make extract_last_codeblock more robust (#49347)
Release Notes:

- N/A
2026-02-17 12:48:36 +02:00
Oleksiy Syvokon 6b86c1984f ep: Repair predictions with too many edits (#49342)
Also fixes batches upload

Release Notes:

- N/A
2026-02-17 12:48:23 +02:00
Oleksiy Syvokon 19d2ac7603 ep: Rework ep repair to use original teacher prompt (#49335)
It now creates multi-turn conversation, where first two messages are the
original teacher prompt and output.

This way, we'll have changes in teacher prompt automatically applied to
repair without having to explicitly sync them.


Release Notes:

- N/A
2026-02-17 08:41:15 +00:00
Oleksiy Syvokon 807f0c7955 ep: Rely on editable_region tags when parsing teacher output (#49334)
Release Notes:

- N/A
2026-02-17 08:37:05 +00:00
Oleksiy Syvokon 2706ac00d5 ep: Add metrics for inserted/deleted tokens (#49330)
Other changes:
- Changed tokenization to more code-aware tokenization from split-commit
- Fixed word-diff implementation which was inefficient and sometimes
incorrect

Release Notes:

- N/A
2026-02-17 09:40:10 +02:00
Max Brunsfeld 274a5f7ee4 Fix EP CLI issues found when generating new teacher predictions (#49327)
Release Notes:

- N/A
2026-02-17 09:33:34 +02:00
Max Brunsfeld e8a00af4a3 Tune edit prediction teacher to leave fewer blank spots in predictions (#49315)
Release Notes:

- N/A
2026-02-16 16:38:43 -08:00
f3b95842c5 Unify zeta endpoints (#48900)
- [ ] Tests or screenshots needed?
- [ ] Code Reviewed
- [ ] Manual QA

Release Notes:

- N/A

---------

Co-authored-by: Zed Zippy <234243425+zed-zippy[bot]@users.noreply.github.com>
Co-authored-by: Max <max@zed.dev>
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2026-02-12 15:24:24 -05:00
Oleksiy Syvokon fc0ffc51df ep: Add SeedCoder prompt format (#49020)
Release Notes:

- N/A
2026-02-12 15:18:28 +02:00
Oleksiy Syvokon 2198cdb67b ep: Add option to use prompt prefill (#48964)
Release Notes:

- N/A
2026-02-12 14:21:16 +02:00
Ben KunkleandTom 315babdcdb ep_cli: Include request_id in rated events and tag rated examples with experiment name and prompt format (#48883)
Closes #ISSUE

- [ ] Tests or screenshots needed?
- [ ] Code Reviewed
- [ ] Manual QA

Release Notes:

- N/A *or* Added/Fixed/Improved ...

Co-authored-by: Tom <tom@zed.dev>
2026-02-10 11:44:16 -05:00
Ben KunkleandTom 0db002e0c9 ep_cli: Add sync deployments command (#48880)
Closes #ISSUE

- [ ] Tests or screenshots needed?
- [ ] Code Reviewed
- [ ] Manual QA

Release Notes:

- N/A *or* Added/Fixed/Improved ...

---------

Co-authored-by: Tom <tom@zed.dev>
2026-02-10 11:31:31 -05:00
Max Brunsfeld 79a3bf5615 Do not pass zeta prompt format in production endpoint (#48541)
This allows us to switch the prompt format without client-side changes.

If we want to experiment with prompt formats or models other than the
currently-deployed one, we can use the raw endpoint, and do prompt
construction and output processing on the client.

This also adds an optional environment parameter to the raw endpoint, so
that we can use that endpoint in the new scheme where we're deploying to
separate environments for different zeta prompt versions.

Release Notes:

- N/A
2026-02-06 00:31:24 -08:00
Oleksiy Syvokon 2f9d85d8c9 ep: Fix parse-output for repaired outputs (#48529)
Release Notes:

- N/A
2026-02-05 21:30:44 +00:00
Marshall Bowers 806e4856fb anthropic: Update types for adaptive thinking (#48517)
This PR updates the Anthropic types with support for [adaptive
thinking](https://platform.claude.com/docs/en/build-with-claude/adaptive-thinking).

We're not actually using adaptive thinking yet.

Release Notes:

- N/A
2026-02-05 19:55:42 +00:00
Oleksiy Syvokon 53d9cf4afe ep: Use programmatic scores as a signal for repair (#48478)
Also, lots of updates to the repair prompt and the ability to keep
previous predictions without having to rewrite them.

Release Notes:

- N/A
2026-02-05 14:07:04 +00:00
Oleksiy Syvokon d09e6cd7b9 ep: Store cursor position in global coordinates (#48469)
This also fixes the isolated whitespace change metric, which is not
takes cursor position into account (it's okay to insert a newline if it
has a cursor on it)

Release Notes:

- N/A
2026-02-05 12:31:12 +00:00
Oleksiy Syvokon 0d6c5d353c ep: Fix trailing newlines parsing (#48473)
Release Notes:

- N/A
2026-02-05 14:29:27 +02:00
Oleksiy Syvokon 38806f59e5 ep: Meaure isolated whitespace change ratio (#48352)
Release Notes:

- N/A
2026-02-04 12:58:19 +00:00
Oleksiy Syvokon df48705f49 ep: Heuristic for detecting wrong editable region (#48343)
Release Notes:

- N/A
2026-02-04 10:52:38 +00:00
Oleksiy Syvokon e45dad2b54 Add ep truncate-patch command to prepare commits evalset (#48204)
Release Notes:

- N/A
2026-02-02 20:06:15 +02:00
Ben Kunkle f7306171bf ep_cli: Integrate ep qa and ep repair into core ep loop (#47987)
Closes #ISSUE

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-02-02 11:32:25 -05:00
Oleksiy Syvokon 5cc4846d67 ep: Add V0131GitMergeMarkersPrefix prompt format (#48145)
Release Notes:

- N/A
2026-02-01 16:11:20 +02:00
Max Brunsfeld 84b8478185 Allow zeta2 to predict next cursor position along with edits (#47916)
* [x] capture and store teacher model's predicted cursor position
* [x] provide cursor position to student during distillation
* [x] eval cursor positions
* [x] parse and apply cursor position predictions at runtime

Release Notes:

- N/A
2026-01-31 16:16:32 +00:00
Ben Kunkle 18516486b2 ep_cli: Only check cursor excerpt for reversals (#48044)
Closes #ISSUE

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-01-30 16:01:16 -05:00
Ben Kunkle 1a9e199d0a ep_cli: Allow dynamically loading prompts (#48046)
Closes #ISSUE

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2026-01-30 14:55:24 -05:00
Oleksiy Syvokon 2e84483245 Add ep split --no-stratify option (#48036)
Release Notes:

- N/A
2026-01-30 16:59:46 +00:00