Commit Graph

380 Commits

Author SHA1 Message Date
Johannes Rieken
a0f90b188c Bring back model picker for inline chat (#276041)
Revert "lock inline chat to its own agent so that must intellisense is disabled"

This reverts commit f04c75b832.
2025-11-07 10:34:57 +00:00
Johannes Rieken
99de6af65e lock inline chat to its own agent so that must intellisense is disabled (#275857)
fixes https://github.com/microsoft/vscode/issues/275819
2025-11-06 09:08:12 -08:00
Johannes Rieken
b855dad790 make sure inline chat shows again after switching tabs (#275534)
* fix https://github.com/microsoft/vscode/issues/275250

* make sure inline chat shows again after switching tabs
2025-11-05 11:31:47 +00:00
Johannes Rieken
ec7952e66e fixes https://github.com/microsoft/vscode/issues/274789 (#275520) 2025-11-05 11:23:34 +01:00
Matt Bierner
a1f7be35bf More sessionId -> sessionResource conversation
- Adopting for code blocks
- Switching to use safer `LocalChatSessionUri.parseLocalSessionId` in a few more spots
- Adopting for some contexts and a few more apis
2025-10-31 11:25:00 -07:00
Johannes Rieken
3628ca5516 Inline chat v2 UI work (#274338)
* disable auto-accept for inline chat

* hide inline chat via ESC more

* inline - render picker below input

* remove unneccessary v2 actions

* fix `Enter` to only accept from input when there is no new text typed

* custom placeholder, use prompt as placeholder while request is on

* no min width for inline chat widget
2025-10-31 12:54:32 +00:00
Matt Bierner
db5ee1e0f4 Convert ChatService to use uris instead of ids in public apis
Moves the chat service public APIs to use uris for identifying sessions instead of ids. These uris are preferred as they work correctly for both contributed and local session

This ends up touch a lot of the chat apis. In most cases, the change is simply to pass in the URI instead of the id. In a few cases where the URI hasn't been fully hooked up, I am using `LocalChatSessionUri` to do this conversation

For the chat session implementation, I also switched to use resource maps to store session specific information instead of a normal map
2025-10-30 17:38:33 -07:00
Johannes Rieken
35d4ea1cd2 Inline chat v2 updates (#273986)
* wip - have a tool that allows inline chat to escape

* wip

* improve move session

* inline chat v2 UI tweaks

* pick up "selected" diagnostics and add them as attachments

* show inline chat widget always above selection

* tweak inline escape tool

* remove `hideOnRequest`

* use `inlineChatApplyEdit` when using inline chat

* make sure to position zone above changes if otherwise inbetween

* 💄

* add logging

* * add inline v2 specific execute toolbar
* add the minimun number of command only
* add keep/discard commands

* Update src/vs/workbench/contrib/inlineChat/browser/inlineChatController.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-29 22:21:45 +00:00
Benjamin Pasero
672c1c1d94 chat - tweak wording around chat and reduce use of copilot (#272839) 2025-10-23 11:40:49 +00:00
Aaron Munger
a842708eab give inline notebook chat its own setting for using v2 controller (#270658)
* make notebook inline v2 usage independent

* try to adjust v1 vs v2 context keys

* fix conditionals, delay cell editor check

* fix v1 context key, editor still not always identified as cell editor

* create alternate inline chat contribs for notebooks

* Revert "create alternate inline chat contribs for notebooks"

This reverts commit f8667269cd.

* fix helper method, use it to get the notebook Editor

* override new method for test

* unused import
2025-10-15 07:57:31 -07:00
Rob Lourens
8882ed69e7 Make agent mode the real default 🚀 (#270592)
* Make agent mode the real default 🚀
Fix #268166

* Fix default mode

* Fix
2025-10-14 01:02:56 +00:00
Johannes Rieken
32036c573c immediately close inline chat UI when session is cancelled (#270742)
fixes https://github.com/microsoft/vscode/issues/265579
2025-10-10 10:02:22 +00:00
Johannes Rieken
b1e37822fb fix hideOnRequest mode so that it doesn't show the inline chat for "good" responses (#270386)
Looks like `ChatResponse#onDidChange` fires with a modified response array after completion...
2025-10-08 09:10:41 -07:00
Matt Bierner
2b636917ce Replace more ...args: any[] with unknown
Follow up on #269213

Typing only change to make `args` type safer
2025-10-06 14:12:10 -07:00
Johannes Rieken
49de261c1a fix a potential stale inline chat window cause (#269999)
re https://github.com/microsoft/vscode/issues/265579
2025-10-06 15:03:07 +02:00
Megan Rogge
a4e7730f6e localize string (#269354)
follow up to #265735
2025-10-01 14:34:11 +00:00
Megan Rogge
5cb209f624 add command to focus last focused chat item, include important info in a11y help (#268362) 2025-09-25 14:11:02 -07:00
Henning Dieterichs
dace6b32b3 Implements code-no-observable-get-in-reactive-context (#267526)
* Implements code-no-observable-get-in-reactive-context

* Improves code

* Fixes lint warnings
2025-09-20 20:29:58 +02:00
Connor Peet
ada50f7949 Add some learning prompts and "send to edit session" for inline chat (#267519)
* wip

* update learnings

* clean 1

* clean 2

* commit update-instructions.prompt.md

* swap back to normal model after being in delegate

* adding generation

* wip

* wip

* update

---------

Co-authored-by: Henning Dieterichs <hdieterichs@microsoft.com>
Co-authored-by: Anthony Kim <anthonykim@microsoft.com>
Co-authored-by: SteVen Batten <sbatten@microsoft.com>
2025-09-19 23:26:52 +02:00
Martin Aeschlimann
50b5aa8954 add ChatRequest.modeInstructions2 with mode metadata to try out things (#267303) 2025-09-17 21:25:37 -07:00
Megan Rogge
8b5b18d87c Indicate inline chat status to screen reader users (#265735)
fix #265734
2025-09-09 12:05:54 -07:00
Rob Lourens
3c409616d5 Rename TextEditor location to EditorInline (#265517)
* EditorInline

* comment
2025-09-07 09:31:09 +10:00
Rob Lourens
ece215ea9b Don't create chat sessions as "editor" location (#265516)
This means inline chat. I got into a state where a chat session was loaded in the panel instead of a chat editor and the location caused issues
2025-09-06 22:26:32 +00:00
Henning Dieterichs
9e1f3e6df0 Implements editTelemetry.codeSuggested and editTelemetry.codeAccepted 2025-08-27 03:48:48 +02:00
Henning Dieterichs
71f925eb98 Adds more metadata to inlineChat.applyEdits 2025-08-19 23:21:11 +02:00
Aaron Munger
1fe14a9d5a create editor integration for Code editors within notebooks (#257911)
* create editor integration for Code editors within notebooks

* push notebook function into notebook file
2025-07-28 18:52:32 +00:00
Elijah King
b8acb41d6c revised chat control, new workspace phrasing and icon (#256784)
* revised chat control, new workspace phrasing

* workspace chat sparkle icon

* updated inline chat placeholder text
2025-07-25 14:13:22 -07:00
Aaron Munger
793fd31e96 use a setting in core and set the location to notebook (#257548)
use a setting in core and set the location from the start
2025-07-23 16:05:57 -07:00
Aaron Munger
57562a894b set notebook inline chat height based on full notebook editor height (#257332)
* notebook inline chat height based on full notebook editor height

* just pass optional param
2025-07-22 13:08:27 -07:00
Martin Aeschlimann
57c041e9e3 make a service out of chatAttachmentResolve.js (#251632)
* make a service out of chatAttachmentResolve.js

* register service
2025-06-17 14:44:06 +00:00
Connor Peet
1ab154c866 break variable entries into their own file for model/parserTypes cycle 2025-06-09 09:47:11 -07:00
Rob Lourens
c6baa8f4ad Simplify ChatModel initialization (#248655)
* Simplify ChatViewPane init slightly

* Simplify ChatModel initialization more
2025-05-12 01:51:06 +02:00
Don Jayamanne
f63c3e0f4e Use codemapper when applying edits to notebook (#246674)
* Address code review comments

* Updates

* Updates

* Updates

* Updates

* Updates

* updates
2025-05-07 15:32:32 +02:00
Johannes Rieken
d8a332ff32 prevent garbage when moving chat from inline chat to panel (#247836)
re https://github.com/microsoft/vscode/issues/247555#issuecomment-2841413915
2025-04-30 12:40:01 +02:00
Johannes Rieken
5bf3e5d3bd fix https://github.com/microsoft/vscode-copilot-release/issues/8611 (#247739) 2025-04-29 15:47:55 +02:00
Johannes Rieken
76a75a5e8e fix awol inline chat widget (#247408) 2025-04-25 18:57:00 +02:00
Johannes Rieken
1a1f7704d9 for inline chat v2 add a inlineChat.hideOnRequest setting (#247319)
this setting control if the inline chat widget hides after making the request or not
2025-04-24 09:44:18 -07:00
Justin Chen
e29475a009 image alt text generation and new arg in vscode.editorChat.start (#245922)
* fix issue with squished images

* remove height auto

* alt text generation and new command arguments

* remove some parenths

* address comments, accept uri arrays only

* remove extra line

* move url checking and such to add file

* some more cleanup, remove extra if line
2025-04-09 10:09:56 -07:00
Johannes Rieken
fc784ffd64 add inlineChat.enableV2 setting (#245327)
This will control/enable the new version of inline chat
2025-04-02 12:38:18 +02:00
Johannes
df8ec180bd chore: WorkingSetEntryState -> ModifiedFileEntryState 2025-03-28 16:48:17 +01:00
Johannes Rieken
27df383fbf inline chat 2 should never show code blocks (#244846)
fixes https://github.com/microsoft/vscode-copilot/issues/15027
2025-03-27 11:30:49 +01:00
Rob Lourens
77ee3930c6 Fix double-disposing edit session (#244395)
And fix inline chat 2
This is complicated. The way that I expect it to work now
- The ChatModel creates the editing session for the right locations and based on the isGlobalEditingSession flag passed in
- stop doesn't dispose the editing session, so it doesn't get disposed twice, but it gets disposed when the ChatModel is disposed
2025-03-23 22:09:21 +01:00
Rob Lourens
1fbb64aee3 Align editing session creation with ChatModel (#244350)
* Align editing session creation with ChatModel

* Fix test

* Fix test
2025-03-23 06:05:21 +00:00
Rob Lourens
bf7d438996 Fix codeblock rendering after reload (#244326)
* Fix codeblock rendering after reload
Meant to remove the `renderCodeBlockPills` flag with #244190

* And this one

* Fix build
2025-03-22 17:06:04 +00:00
Rob Lourens
8ef2f681ce Chat view unification (#243285)
* Start enabling unified chat mode

* Move ChatAgentLocation to avoid import cycle. Update imports

* fix more imports

* More work

* Add ChatMode, make agent mode be session-specific, not global
Towards unifying chat views

* Fix mode for transferred session and request parser

* Fixes

* Fix defaultAgent, don't do intent detection

* Fixes

* Don't show mode picker in other locations

* Add chatMode context key

* Fix "new edit session" in unified

* Update context actions

* Update execute actions

* Title actions

* Update more commands
2025-03-13 00:24:40 +00:00
Johannes Rieken
393c628829 fix https://github.com/microsoft/vscode/issues/241839 (#242056) 2025-02-26 13:03:21 +01:00
Johannes Rieken
c5549bc00e asorted fixes (#241684)
* fix https://github.com/microsoft/vscode/issues/241674

* reveal inline chat when switching back to editor

* fixes https://github.com/microsoft/vscode-copilot/issues/13260
2025-02-24 10:45:32 +01:00
Johannes Rieken
ae5010d6ad move chat overlay into workbench grid (#240808)
* make chat editing overlay a workbench editor overlay (not just a code editor overlay), same for editor specific context key, they should not be limited to code editors

* * centralize context key handling into `chatEditoringEditorContextKeys`
*  workbench chat overlay also reacts to inline chat sessions

* fix leak in code lens controller

* 💄

* make sure `EditingSessionAction` find the right widget

* add `IModifiedFileEntryNavigator` to allow change navigation from "the inside"

* remove code editor based chat overlay logic
2025-02-14 16:38:48 +00:00
Johannes
07f4329e12 reveal widget when response is cancelled, errored, or without code changes
fixes https://github.com/microsoft/vscode-copilot/issues/12392
2025-02-07 15:33:52 +01:00
Johannes Rieken
09a758fb3f refactor the new inline chat controller so that switching is simpler (#239937) 2025-02-07 14:08:52 +01:00