You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: blogs/2025/next-edit-suggestions.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -70,11 +70,11 @@ NES can also help with more challenging mistakes in logic, like a return stateme
70
70
**Using newly added variables or logic:** Copilot NES helps you use new code you just added. This may be a small change, like calling a new method parameter in the actual method.
71
71
72
72
It could also be more complex: if you added a new command to your VS Code extension's `extension.ts`, NES will first suggest to clean up the command in `extension.ts`. Then when you open `package.json`, NES may suggest registering that command as well:
73
-

73
+

74
74
<!--  -->
75
75
<!--  -->
76
76
77
-
**Refactoring:** If you use a new name or naming pattern, Copilot NES suggests to rename subsequent variables similarly.
77
+
**Refactoring:** If you use a new name or naming pattern, Copilot NES suggests to rename subsequent variables similarly. After copy-pasting some code, NES will suggest how to adjust it to match the current code where the paste happened.
78
78
79
79
## Share your feedback
80
80
Copilot NES is rapidly evolving, and we can't wait to get your feedback via issues in [our repo](https://github.com/microsoft/vscode-copilot-release) – this will be instrumental to improving the experience.
Copy file name to clipboardExpand all lines: docs/copilot/ai-powered-suggestions.md
+26-24Lines changed: 26 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -63,9 +63,9 @@ The following example shows how to instruct Copilot to create a class in TypeScr
63
63
64
64
## Next Edit Suggestions (preview)
65
65
66
-
Inline suggestions are great at autocompleting a section of code. But since most coding activity is editing existing code, it's a natural evolution of Copilot completions to also help with edits, both at the cursor and further away. Edits are often not made in isolation - there's a logical flow of what edits need to be made in different scenarios. Copilot Next Edit Suggestions (aka "Copilot NES") is this evolution.
66
+
Inline suggestions are great at autocompleting a section of code. But since most coding activity is editing existing code, it's a natural evolution of Copilot code completions to also help with edits, both at the cursor and further away. Edits are often not made in isolation - there's a logical flow of what edits need to be made in different scenarios. Copilot Next Edit Suggestions (aka "Copilot NES") is this evolution.
67
67
68
-
Based on the edits you're making, NES both predicts the location of the next edit you'll want to make and what that edit should be. NES helps you stay in the flow, suggesting future changes relevant to your current work, and you can simply `kbstyle(Tab)` to quickly navigate and accept Copilot's suggestions. Suggestions may span a single symbol, an entire line, or multiple lines, depending on the scope of the potential change.
68
+
Based on the edits you're making, Copilot NES both predicts the location of the next edit you'll want to make and what that edit should be. NES helps you stay in the flow, suggesting future changes relevant to your current work, and you can simply `kbstyle(Tab)` to quickly navigate and accept Copilot's suggestions. Suggestions may span a single symbol, an entire line, or multiple lines, depending on the scope of the potential change.
69
69
70
70
> [!NOTE]
71
71
> Copilot NES is currently in preview. You can enable NES via the VS Code setting `setting(github.copilot.nextEdits.enabled)`.
@@ -76,51 +76,53 @@ Based on the edits you're making, NES both predicts the location of the next edi
76
76
>
77
77
> You can learn more about [managing policies for Copilot in your organization](https://docs.github.com/en/copilot/managing-copilot/managing-github-copilot-in-your-organization/managing-policies-for-copilot-in-your-organization#enabling-copilot-features-in-your-organization).
78
78
79
-
<!-- TODO: Add video from blog -->
79
+

80
+
<!-- TODO: Update to video with voiceover from Olivia -->
80
81
81
82
### Navigate and accept edit suggestions
82
83
83
84
You can quickly navigate suggested code changes with the `kbstyle(Tab)` key, saving you time to find the next relevant edit (no manual searching through files or references required). You can then accept a suggestion with the `kbstyle(Tab)` key again.
84
85
85
-
An arrow in the gutter indicates if there is an edit suggestion available:
86
-

87
-
88
-
If an edit suggestion is below the current editor view, the arrow will point down instead of right:
89
-

86
+
An arrow in the gutter indicates if there is an edit suggestion available. If an edit suggestion is below the current editor view, the arrow will point down instead of right:
87
+

88
+
<!--  -->
89
+
<!--  -->
90
90
91
91
You can hover over the arrow to explore the edit suggestion menu, which includes keyboard shortcuts and settings configuration:
92
92

93
93
94
94
### Use cases for Next Edit Suggestions
95
95
96
-
**Changing intent**
96
+
**Catching and correcting mistakes**
97
97
98
-
***Copilot suggests changes to the rest of your code that match a new change in intent.** For example, when changing a class from `Point` to `Point3D`, Copilot will suggest to add a `z` variable to the class definition:
99
-

98
+
***NES helps with simple mistakes like typos.** It'll suggest fixes where letters are missing or swapped, like `cont x = 5` or `conts x = 5`, which should've been `const x = 5`.
99
+

100
+
***NES can also help with more challenging mistakes in logic**, like where a statement should've had `<` instead of `<=`:
101
+

102
+
or a comparison that should've used `&&` instead of `||`:
103
+

100
104
101
-
After accepting the change, NES next recommends adding `z` to the distance calculation:
102
-

105
+
**Changing intent**
103
106
104
-
**Adding new variables or logic**
107
+
***Copilot suggests changes to the rest of your code that match a new change in intent.** For example, when changing a class from `Point` to `Point3D`, Copilot will suggest to add a `z` variable to the class definition. After accepting the change, NES next recommends adding `z` to the distance calculation:
108
+

109
+
<!-- 
110
+
 -->
105
111
106
-
***Using newly added arguments, variables, or functions**. Copilot NES helps you use new code you just added. This may be a small change, like calling a new method parameter in the actual method.
112
+
**Adding new variables or logic**
107
113
108
-
It could also be more complex: if you added a new command to your VS Code extension's `extension.ts`, NES will first suggest to clean up the command in `extension.ts`:
109
-

114
+
***Using newly added arguments, variables, or functions**. NES helps you use new code you just added. This may be a small change, like calling a new method parameter in the actual method.
110
115
111
-
And then when you open `package.json`, NES may suggest registering that command as well:
112
-

116
+
It could also be more complex: if you added a new command to your VS Code extension's `extension.ts`, NES will first suggest to clean up the command in `extension.ts`. Then when you open `package.json`, NES may suggest registering that command as well:
117
+

118
+
<!-- 
119
+
 -->
113
120
114
121
**Refactoring**
115
122
116
123
***Rename a variable once in a file, and Copilot will suggest to update it everywhere else.** If you use a new name or naming pattern, Copilot suggests to rename subsequent variables similarly.
117
124
***Matching code style**. After copy-pasting some code, Copilot will suggest how to adjust it to match the current code where the paste happened.
118
125
119
-
**Correcting mistakes**
120
-
121
-
***Copilot helps with mistakes like typos.** It'll suggest fixes where letters are missing or swapped, like `cont x = 5` or `conts x = 5`, which should've been `const x = 5`.
122
-
***Copilot can also help with mistakes in logic**, like where a statement should've had `<` instead of `<=`, or an `OR` statement that should've been an `AND`.
0 commit comments