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: docs/rfds/next-edit-suggestions.mdx
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -306,6 +306,7 @@ The client requests a suggestion by calling `nes/suggest`. Context fields are in
306
306
`selection` is the current text selection range, if any. When the selection is empty (cursor is a point), this field may be omitted or have `start` equal to `end`. Agents can use selection state to predict replacements or transformations of the selected text.
307
307
308
308
`triggerKind` is one of:
309
+
309
310
-`"automatic"` — triggered by user typing or cursor movement
310
311
-`"diagnostic"` — triggered by a diagnostic (error/warning) appearing at or near the cursor position. The client includes the relevant diagnostics in the `diagnostics` context field so the agent can target a fix.
311
312
-`"manual"` — triggered by explicit user action (keyboard shortcut)
@@ -385,24 +386,29 @@ A suggestion is one of three kinds: an **edit** (text changes), a **jump** (navi
385
386
```
386
387
387
388
Action suggestions reference an IDE action that the client previously advertised in its capabilities:
389
+
388
390
-`actionId` — matches an `id` from the client's advertised `ideActions`.
389
391
-`arguments` — matches the parameter schema declared by the client for that action.
390
392
391
393
A response may contain a mix of edit, jump, and action suggestions. The client decides how to present them (e.g. inline ghost text for edits, a navigation hint for jumps).
392
394
393
395
Each suggestion contains:
396
+
394
397
-`id` — unique identifier for accept/reject tracking.
395
398
-`kind` — `"edit"`, `"jump"`, or `"action"`.
396
399
397
400
Edit suggestions additionally contain:
401
+
398
402
-`edits` — one or more text edits to apply.
399
403
-`cursorPosition` — optional suggested cursor position after applying edits.
400
404
401
405
Jump suggestions additionally contain:
406
+
402
407
-`uri` — the file to navigate to.
403
408
-`position` — the target position within that file.
404
409
405
410
Action suggestions additionally contain:
411
+
406
412
-`actionId` — the IDE action to perform (must match a client-advertised action `id`).
407
413
-`arguments` — action parameters matching the schema from the client's capability.
0 commit comments