Skip to content

edit_prediction: Add Mercury accept/reject tracking (#48306) (cherry-pick to stable)#48403

Merged
zed-zippy[bot] merged 1 commit intov0.222.xfrom
cherry-pick-v0.222.x-e39c1906
Feb 4, 2026
Merged

edit_prediction: Add Mercury accept/reject tracking (#48306) (cherry-pick to stable)#48403
zed-zippy[bot] merged 1 commit intov0.222.xfrom
cherry-pick-v0.222.x-e39c1906

Conversation

@zed-zippy
Copy link
Contributor

@zed-zippy zed-zippy bot commented Feb 4, 2026

Cherry-pick of #48306 to stable


Summary

Adds accept/reject tracking for Mercury edit predictions.

Changes

Sends events to https://api-feedback.inceptionlabs.ai/feedback when:

Accept — user presses Tab
Reject — user presses Escape
Ignore — prediction dismissed implicitly (typing, cursor move, etc.)

Added discard_explicit method to the delegate trait to distinguish
explicit vs implicit dismissal. Updated reject_prediction and
reject_current_prediction methods with an explicit bool parameter to
thread this through to the Mercury feedback logic. Other providers are
unaffected—they use the default implementation.

Feedback is fire-and-forget in a background thread, only sent for
predictions that were shown.

Data Collected

  • Request ID (returned from Inception API)
  • User action (either accept/reject/ignore)
  • Client Zed version (to track updates made to Zed client which could
    potentially affect nextedit implementation)

Release Notes:

  • N/A

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

### Summary
Adds accept/reject tracking for Mercury edit predictions.

### Changes
Sends events to https://api-feedback.inceptionlabs.ai/feedback when:

Accept — user presses Tab
Reject — user presses Escape
Ignore — prediction dismissed implicitly (typing, cursor move, etc.)

Added `discard_explicit` method to the delegate trait to distinguish
explicit vs implicit dismissal. Updated `reject_prediction` and
`reject_current_prediction` methods with an `explicit` bool parameter to
thread this through to the Mercury feedback logic. Other providers are
unaffected—they use the default implementation.

Feedback is fire-and-forget in a background thread, only sent for
predictions that were shown.

### Data Collected
- Request ID (returned from Inception API)
- User action (either accept/reject/ignore)
- Client Zed version (to track updates made to Zed client which could
potentially affect nextedit implementation)


Release Notes:

- N/A

---------

Co-authored-by: Ben Kunkle <ben@zed.dev>
@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Feb 4, 2026
@zed-zippy zed-zippy bot merged commit 14835b0 into v0.222.x Feb 4, 2026
27 checks passed
@zed-zippy zed-zippy bot deleted the cherry-pick-v0.222.x-e39c1906 branch February 4, 2026 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant