refactor: replace IInlineChatEditStrategy with InlineChatToolCalling for improved edit handling#312329
Merged
refactor: replace IInlineChatEditStrategy with InlineChatToolCalling for improved edit handling#312329
Conversation
Co-authored-by: Copilot <copilot@github.com>
…for improved edit handling
Contributor
There was a problem hiding this comment.
Pull request overview
Refactors the Copilot inline chat editing flow to use a dedicated tool-calling loop (replacing the prior edit-strategy abstraction), and removes now-obsolete configuration/telemetry related to the previous heuristic selection-handling path.
Changes:
- Replaces
IInlineChatEditStrategy-based branching withInlineChatToolCallingin the inline chat intent flow. - Removes the
inlineChat.selectionRatioThresholdexperimental configuration (and its package.json/nls entries). - Removes selection-length telemetry plumbing tied to AST/selection adjustment metadata.
Show a summary per file
| File | Description |
|---|---|
| extensions/copilot/src/platform/configuration/common/configurationService.ts | Removes the InlineChatSelectionRatioThreshold config key constant. |
| extensions/copilot/src/extension/prompts/node/inline/test/inlineChat2Prompt.spec.tsx | Updates test import to use the new prompt module location. |
| extensions/copilot/src/extension/prompts/node/inline/inlineChatEditCodePrompt.tsx | Removes DocumentToAstSelectionData telemetry metadata emission and related imports. |
| extensions/copilot/src/extension/prompt/node/chatParticipantTelemetry.ts | Removes selection length measurements and the associated GDPR fields. |
| extensions/copilot/src/extension/intents/node/editCodeIntent.ts | Removes a stale commented telemetry line referencing removed metadata. |
| extensions/copilot/src/extension/inlineChat/node/inlineChatPrompt.tsx | Adjusts import paths after prompt/module reorganization. |
| extensions/copilot/package.nls.json | Removes localized description for the deleted config setting. |
| extensions/copilot/package.json | Removes the github.copilot.chat.inlineChat.selectionRatioThreshold configuration contribution. |
Copilot's findings
- Files reviewed: 9/9 changed files
- Comments generated: 2
lramos15
approved these changes
Apr 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.