Commit Graph

175 Commits

Author SHA1 Message Date
Harald Kirschner 7aa17fc25e fix: align promptCategorization.requestId with panel.request for telemetry joins (#3874)
Co-authored-by: Harald Kirschner <digitarald@gmail.com>
2026-02-19 23:57:48 +00:00
Don Jayamanne 58151ec8fe Adopt the latest github copilot npm (#3786)
* Adopt the latest github copilot npm

* Updates

* Updates

* Updates

* Updates

* Fixes

* Fixes

* Fixes

* Fixes

* Updates to the tests

* Fix tests
2026-02-19 08:46:17 +00:00
Don Jayamanne 242fffd027 Update background handling of update_todo tool (#3845) 2026-02-19 05:51:20 +00:00
Bhavya U f3e6859c16 Add support for local repository memory and update telemetry events (#3841)
* Add support for local repository memory and update telemetry events

* Update memory command labels for clarity in the UI

* update test

* Add repository memory section to snapshot tests for clarity
2026-02-19 05:51:04 +00:00
Don Jayamanne b7ebca4bfb Add authorization checks in Background agents (#3705)
* Add authorization checks in Background agents

* fix tests

* Fixes

* Fixes with tests

* Updates

* Fix tests
2026-02-17 23:59:44 +00:00
Rob Lourens 8ddd2a06e5 Disposable fixes (#3784)
Copilot-assisted
2026-02-16 23:20:55 +00:00
Ulugbek Abdullaev 7d728b836e swb: fix support for external NES stests for windows & "run test once" (#3768)
* swb: fix: make external NES stest running windows-compatible

* swb: support running a single external test

* address ccr
2026-02-16 15:21:10 +00:00
Ulugbek Abdullaev 0c77656331 nes: feat: more diff merging strategies (#3763)
also fix that two adjacent line changes would result in two diff hunks
2026-02-16 11:15:45 +00:00
Don Jayamanne d316210e87 Enhance Copilot CLI integration with built-in model picker (#3757)
* Use built-in model dropdown for background agents

* Fixes

* Support compact command in background agent

* Revert tests
2026-02-16 04:38:35 +00:00
Rob Lourens a4ffdcf03b Sync chatParticipantPrivate.d.ts with vscode (#3734)
* Sync chatParticipantPrivate.d.ts

* Sync ChatRequestEditorData with vscode
2026-02-13 21:07:31 +00:00
Ulugbek Abdullaev c92f112bd5 swb: support external NES tests (#3719) 2026-02-13 14:18:05 +00:00
Ulugbek Abdullaev a8e4b9fe96 ghostText: log network requests to the log tree (#3669)
* ghostText: log network requests to the log tree

* nest requests

* Update src/platform/nesFetch/node/completionsFetchServiceImpl.ts

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

* Update src/platform/nesFetch/node/completionsFetchServiceImpl.ts

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

* address cpoilot comments

* address cpoilot comments

* Revert "Update src/platform/nesFetch/node/completionsFetchServiceImpl.ts"

This reverts commit da984b07119716d8585ca799851ea17cb5b4a7a4.

* fix tests

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-12 11:20:56 +00:00
Ulugbek Abdullaev 5e0ca23866 nes: flush copilot-nes-oct cache and run external nes stests (#3605)
* nes: flush copilot-nes-oct cache and run external nes stests

* update nes stests
2026-02-10 13:45:19 +00:00
Rob Lourens e5cd86beeb Rename /summarize to /compact, add optional extra instructions (#3556)
* Rename /summarize to /compact, add optional extra instructions

* Update simulation baseline
2026-02-08 18:11:03 +00:00
Rob Lourens 84b8b46bd5 Add session transcript service for hooks (#3545)
* Add session transcript service for hooks

Implement JSONL-based session transcript service that records
conversation turns, tool executions, and assistant messages for
hook consumers.

Key changes:
- New ISessionTranscriptService interface and SessionTranscriptService
  implementation with buffered writes and automatic old transcript cleanup
- Integrate transcript logging into tool calling loop: user messages,
  assistant messages, tool execution start/complete, turn boundaries
- Auto-flush transcript and inject transcript_path into hook input
- Race flush with 500ms timeout to avoid blocking hook execution
- Gate transcript creation on ChatRequest.hasHooksEnabled
- Include copilotVersion and vscodeVersion in session.start entry
- Add timestamp to IToolCallRound for transcript timing
- Add hasHooksEnabled to ChatRequest interface and all implementors

* Fixes
2026-02-07 02:04:46 +00:00
Matt Bierner 34b17f117d Remove @workspace chat participant (#3492)
* Remove `@workspace` chat participant

For https://github.com/microsoft/vscode/issues/292972

Removes the `@workspace` chat participant since this is now an outdated (and confusing) way to use code search. For now we'll keep the commands but I've moved them under the default agent instead

* Updating tests too and fixing some references
2026-02-06 00:21:09 +00:00
Connor Peet ba2e206efe tools: cleanup unused pause logic (#3488)
We removed the 'pause' feature back in ~June, cleanup logic we still had
around it. This removes:

- The PauseController class which was no longer being used
- onPaused event parameters from chat participant, request, and intent
  handlers
- Pause-related event listening and stream pausing logic
- Simplified throwIfCancelled to be synchronous since it no longer needs
  to wait for pause resumption

(Commit message generated by Copilot)
2026-02-05 18:24:07 +00:00
Connor Peet 8ca2807e66 chat: wire up yieldrequested for steering messages (#3473)
* chat: wire up yieldrequested for steering messages

Allows the client to do a 'soft cancel' after a tool call happens before returning back to the model, or before the next turn.

* fix compile
2026-02-05 16:05:57 +00:00
Don Jayamanne 0e7329b0ac background agent stests to verify grep/glob tools (#3445)
* background agent stests to verify grep/glob tools

* Skip
2026-02-04 20:32:43 +00:00
Don Jayamanne 68dd8b04dc Auto approve viewing of attached images (#3223)
* Trust images created by BG session

* Updates

* Updates to display name

* Update src/extension/prompts/node/agent/copilotCLIPrompt.tsx

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

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-28 06:46:30 +00:00
Karthik Nadig 86e5f95490 Add question functionality and related types for chat interactions (#3157)
* Add question carousel functionality and related types for chat interactions

* feat: enhance logging for question carousel processing and answer conversion

* feat: enhance answer processing in AskQuestionsTool to support freeform text input

* cleanup: remove unused AskQuestionResult type from IQuestionAnswer

* clenaup: restore package.json

* feat: enhance AskQuestionsTool to handle no stream scenario and improve carousel answer conversion
2026-01-26 19:23:30 +00:00
Ulugbek Abdullaev 311d7fab8b update to latest vscode sources (#3118) 2026-01-26 09:52:58 +00:00
Johannes Rieken e8e9b03ba7 Tweak prompt selection and also remind model to do all edits in a single tool call (#3125)
* Tweak prompt selection and also remind model to do all edits in a single tool call

* (fix) correct tool name

* stest

* more stest drama
2026-01-26 08:36:17 +00:00
Don Jayamanne 44a6166c55 Update Copilot CLI stests to include mcp server (#3107) 2026-01-23 07:50:36 +00:00
Connor Peet ba56721dfa tools: add support for model-specific tool registration (#2857)
* tools: add support for model-specific tool registration

This PR goes with https://github.com/microsoft/vscode/pull/287666

This allows the registration of tools that are scoped to specific
language models. These tools can be registered at runtime with
definitions derived from e.g. the server.

I think we should adopt this and go away from the current
`alternativeDefinitions` pattern which we have used previously.

Example of having tools specific for GPT 4.1 vs 4o:

```ts
ToolRegistry.registerModelSpecificTool(
	{
		name: 'gpt41_get_time',
		inputSchema: {},
		description: 'Get the current date and time (4.1)',
		displayName: 'Get Time (GPT 4.1)',
		toolReferenceName: 'get_time',
		source: undefined,
		tags: [],
		models: [{ id: 'gpt-4.1' }],
	},
	class implements ICopilotTool<unknown> {
		invoke() {
			return new vscode.LanguageModelToolResult([new vscode.LanguageModelTextPart('Current year is 2041 (GPT 4.1)')]);
		}
	}
);

ToolRegistry.registerModelSpecificTool(
	{
		name: 'gpt4o_get_time',
		inputSchema: {},
		description: 'Get the current date and time (4o)',
		displayName: 'Get Time (GPT 4o)',
		toolReferenceName: 'get_time',
		source: undefined,
		tags: [],
		models: [{ id: 'gpt-4o' }],
	},
	class implements ICopilotTool<unknown> {
		invoke() {
			return new vscode.LanguageModelToolResult([new vscode.LanguageModelTextPart('Current year is 2040 (GPT 4o)')]);
		}
	}
);
```

* demo

* fix

* overrides

* add overridesTool

* fix inverted logic

* test fixes and back compat

* make memory tool model specific

* fix tests and contribute memory to the vscode toolset

* verison

* fix unit tests

* rm config

* fix missing askquestions

---------

Co-authored-by: bhavyaus <bhavyau@microsoft.com>
2026-01-22 18:34:05 +00:00
Christof Marti a2a163471d Cleanup Response (#2876) 2026-01-15 20:28:17 +00:00
Ulugbek Abdullaev 065165159d ghost: use CompletionsFetchService (#2694)
* ghost: use CompletionsFetchService

also comes with lots of fixes in CompletionsFetchService

* ghost: stream: refactor: extract CopilotAnnotations types to platform/

* completionFetchService: remove hard-coding n=1

* support for copilot_annotations

* fix incorrect import

* fix incorrect destroy of http connection

* fix: update response accumulation logic in CompletionAccumulator

* refresh token more correctly
2026-01-15 12:37:16 +00:00
Don Jayamanne dfaa4f6d5f Update Github Copilot to latest version (#2864)
* Update to latest version of Github Copilot CLI

* Use 0.0.381

* Reverts

* Update src/extension/agents/copilotcli/node/copilotcliSession.ts

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

* Updates

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-15 01:36:52 +00:00
Matt Bierner c321d9b071 Add cancellation to trigger remote indexing (#2860) 2026-01-14 22:24:28 +00:00
Matt Bierner 4c06505696 Add progress messages for building external index (#2820) 2026-01-13 23:35:49 +00:00
Don Jayamanne d185680f57 Fix race conditions when running CLI stests (#2805) 2026-01-13 04:47:52 +00:00
Matt Bierner 7da3c60129 Fixes for external ingest (#2778)
* Fixes for external ingest

- Make sure we use relative paths
- Add command to clear
- Avoid requests if the index is already up to date

* Small cleanup
2026-01-10 00:14:12 +00:00
Ulugbek Abdullaev 04f265596f completionsFetchService: improve API to prep it for ghost-text use (#2693)
* fetcherService: change `FetchOptions#json` to be `unknown` instead of `any` and document it

* completionsFetchService: don't use `any`

* completionsFetchService: less logic within service

try reducing logic such that the service's easier to evolve

* completionsFetchService: refactor: cleanup

* address comments

* fix ci
2026-01-01 21:39:00 +00:00
Don Jayamanne 554a6adfaa Update CLI tests to test terminal commands (#2473)
* Use fs.mkdir with recursive option instead of IFileSystem.createDirectory to account for dir already existing

* Update CLI tests to test terminal commands

* Fixes

* Updates

* More fixes
2025-12-23 08:45:45 +00:00
Don Jayamanne c3083d8402 Give preference to paths in WorkTree (#2542)
* Give preference to paths in WorkTree as opposed to workspace

* fix tests
2025-12-11 22:55:49 +00:00
Johannes Rieken 1b8308f1fd Inline chat handles empty selections explicitly (#2535)
* handle empty selection better in inline chat

* stests

* add unit tests

* Update src/extension/prompts/node/inline/inlineChat2Prompt.tsx

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

* stests

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-11 13:50:17 +00:00
Ulugbek Abdullaev 3417fc6d7c update cache (#2533) 2025-12-11 10:36:12 +00:00
Matt Bierner 3c8134184b Enable no-unexternalized-strings in repo (#2448)
Enables the same `no-unexternalized-strings` with have in `vscode` in this repo. This make sure we have a more consistent style across repos and when generating edits
2025-12-05 18:45:12 +00:00
Johannes Rieken 02d7754061 * drive inline chat feedback telemetry from CopilotInteractiveEditorResponse (#2435)
* `CopilotInteractiveEditorResponse.kind` is always 'ok' -> remove it

fixes https://github.com/microsoft/vscode/issues/280959
2025-12-05 13:26:45 +00:00
Ulugbek Abdullaev aee2abe2e1 nes: joint: don't enforce cache delay if document hasn't changed (#2409) 2025-12-04 22:13:16 +00:00
Johannes Rieken 36f0ab1f6f inline chat fixes (#2348)
* make sure the exit-tool is called when nothing else has been called

fixes https://github.com/microsoft/vscode/issues/280775

* tweak inline prompt for better prefix-caching

https://github.com/microsoft/vscode-internalbacklog/issues/6337
2025-12-03 10:14:20 +00:00
Ulugbek Abdullaev 3c78ed81dd nes: support /models on proxy and model picker (#2325) 2025-12-02 14:14:53 +00:00
Matt Bierner 4daa76719c Split up code search files (#2300) 2025-12-01 19:03:24 +00:00
Matt Bierner 79099f491d Re-work code search implementation (#2279)
* init

* Re-work code search implementation

Prepping for future work by making it easier to have individual repos in a workspace handle code search their own way. The previous implementation had gotten kind of unwieldy after we bolted on the ADO support. Extending it further would have made this even worse
2025-12-01 01:28:54 +00:00
Rob Lourens 2307f0294f Custom todo tool description for gpt models (#2274)
Fix #269031
2025-11-30 22:50:43 +00:00
Don Jayamanne e03ab5c0f8 Support image attachments in Copilot CLI (#2270)
* Support image attachments in Copilot CLI

* Fix tests
2025-11-30 05:23:51 +00:00
Johannes Rieken 0231290715 keep intent detection for inline v1 intact (#2264) 2025-11-28 14:29:05 +00:00
Don Jayamanne aa2b9761fb Exclude incorrect workspace chat ref vars for Copilot CLI (#2254) 2025-11-28 06:17:34 +00:00
Ulugbek Abdullaev 71803ce30f nes: support jump-to label (#2248)
* nes: update to latest core API for completions

* nes: support jump-to
2025-11-27 18:41:52 +00:00
Johannes Rieken bfc3fe5285 check edit tool results for errors and try again if editing failed (#2246)
* check edit tool results for errors and try again if editing failed

https://github.com/microsoft/vscode/issues/275056

* Update src/extension/prompts/node/inline/inlineChat2Prompt.tsx

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

* fix prompt

* update-baseline

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-27 17:09:20 +00:00