* Implement MCP gateway for Claude agent
This will hook up any MCP servers installed via VS Code and available via VS Code to Claude.
It think there should be some UX work in Core to enable/disable tools, but from an extension perspective this should be good.
ref https://github.com/microsoft/vscode/issues/287660
* feedback
* 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
* Fix slash command handler not taking the command into consideration
This broke at some point, not sure when... but now it's plumbed through.
* feedback
* Initial plan
* Add tool-calling reinforcement to Gemini prompts to prevent hallucinated tool calls
The Gemini Pro model was hallucinating tool calls (describing them in text
instead of invoking them) after 2-3 turns. This adds explicit instructions
to both Gemini system prompts and the reminder instructions to reinforce
that tools must be invoked through the tool-calling mechanism, not described
in prose.
Co-authored-by: vijayupadya <41652029+vijayupadya@users.noreply.github.com>
* update prompts
* add br ending
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: vijayupadya <41652029+vijayupadya@users.noreply.github.com>
In general you should not call the refresh handler like this yourself because it won't show anything in the UI (it's fine to call the actual implementation that does the refresh). I'm going to update the api so that there is no confusing `refreshHandler` property toi avoid this confusion
* Initial plan
* Add usage handler mechanism for Claude context window widget
- Add UsageHandler type and methods to IClaudeSessionStateService
- Set usage handler in claudeChatSessionContentProvider request handler
- Wire up usage reporting in ClaudeStreamingPassThroughEndpoint
- Extract usage from AnthropicMessagesProcessor completion and call handler
Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
* Add unit tests for usage handler in ClaudeSessionStateService
- Add tests for getUsageHandlerForSession
- Add tests for setUsageHandlerForSession
- Verify handler preservation across state changes
- Verify handler can be called correctly
Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
* don't do the separate cache section
* a test
* include compaction
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: TylerLeonhardt <2644648+TylerLeonhardt@users.noreply.github.com>
Co-authored-by: Tyler Leonhardt <tyleonha@microsoft.com>
* Add guard for trailing assistant messages in Messages API to prevent prefill errors
* Refine guard for trailing assistant messages in Messages API to prevent prefill errors
* update background summarization with cancellation token support and add tests
* feat: add telemetry for background compaction orchestration decisions and outcomes
* feat: add summarization source tracking for background and foreground operations
* update background summarization with cancellation token support and add tests
* refactor: update progress reporting in AgentIntentInvocation and enhance background summarizer tests
* refactor: update background summarizer to use token parameter in start method
* Initial plan
* Fix non-existent files incorrectly treated as external
- Add file existence check in isFileExternalAndNeedsConfirmation()
- Non-existent files now return false (not external) to prevent confirmation dialog
- Actual tool invocation will fail with proper "file not found" error
- Update tests to reflect new behavior
Co-authored-by: connor4312 <2230985+connor4312@users.noreply.github.com>
* Address code review feedback
- Add comprehensive comment explaining error handling tradeoff
- Add test suite with MockFileSystemService to verify existing external files still need confirmation
- Tests confirm the fix works correctly for both existing and non-existing files
Co-authored-by: connor4312 <2230985+connor4312@users.noreply.github.com>
* update
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: connor4312 <2230985+connor4312@users.noreply.github.com>
Co-authored-by: Connor Peet <connor@peet.io>