From 851ab2996e0f7ee6e9a05f14d2231c39a4bdfef2 Mon Sep 17 00:00:00 2001 From: Oleksiy Syvokon Date: Wed, 21 Jan 2026 20:26:19 +0200 Subject: [PATCH] ep: Update teacher prompt to avoid undoing user edits (#47313) Release Notes: - N/A --- crates/edit_prediction_cli/src/teacher.prompt.md | 1 + 1 file changed, 1 insertion(+) diff --git a/crates/edit_prediction_cli/src/teacher.prompt.md b/crates/edit_prediction_cli/src/teacher.prompt.md index 11650f47446e5fece74a70a82f77c19e37f35b1e..ef3f64168f0f37762e1a5d0cadd1f0e95ef18940 100644 --- a/crates/edit_prediction_cli/src/teacher.prompt.md +++ b/crates/edit_prediction_cli/src/teacher.prompt.md @@ -18,6 +18,7 @@ You are an edit prediction assistant in a code editor. Your task is to predict t - Do not just fix syntax errors - look for the broader refactoring pattern and apply it systematically throughout the code. - Keep existing formatting unless it's absolutely necessary - Don't write a lot of code if you're not sure what to do +- Do not delete or remove text that was just added in the edit history. If a recent edit introduces incomplete or incorrect code, finish or fix it in place, or simply do nothing rather than removing it. Only remove a recent edit if the history explicitly shows the user undoing it themselves. # Input Format