Skip to content

Avoidincluding customizations variables into CLI prompt as context#4392

Merged
DonJayamanne merged 3 commits intomainfrom
don/endless-crocodile
Mar 13, 2026
Merged

Avoidincluding customizations variables into CLI prompt as context#4392
DonJayamanne merged 3 commits intomainfrom
don/endless-crocodile

Conversation

@DonJayamanne
Copy link
Collaborator

No description provided.

@DonJayamanne DonJayamanne self-assigned this Mar 13, 2026
@DonJayamanne DonJayamanne marked this pull request as ready for review March 13, 2026 02:04
Copilot AI review requested due to automatic review settings March 13, 2026 02:04
@DonJayamanne DonJayamanne enabled auto-merge March 13, 2026 02:05
@vs-code-engineering vs-code-engineering bot added this to the 1.112.0 milestone Mar 13, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates Copilot CLI prompt construction to exclude the VS Code “customizations index” prompt reference from the generated prompt context (references/attachments), preventing copilot-instructions–derived customizations from being sent as regular context.

Changes:

  • Add a new prompt-variable predicate/constant for identifying the customizations index reference (vscode.customizations.index).
  • Filter out the customizations index reference when constructing Copilot CLI prompt references/attachments.
  • Add a unit test ensuring the customizations index is excluded while normal file references remain included.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
src/extension/prompts/node/agent/test/parseAttachments.spec.ts Adds a test asserting customizations index references/attachments are excluded from the resolved prompt output.
src/extension/prompt/common/chatVariablesCollection.ts Introduces CustomizationsIndexId and isCustomizationsIndex helper for identifying the special reference.
src/extension/chatSessions/copilotcli/node/copilotcliPromptResolver.ts Excludes the customizations index from Copilot CLI prompt variable processing.

DonJayamanne and others added 2 commits March 13, 2026 13:26
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@DonJayamanne DonJayamanne added this pull request to the merge queue Mar 13, 2026
Merged via the queue into main with commit a89b1fc Mar 13, 2026
19 checks passed
@DonJayamanne DonJayamanne deleted the don/endless-crocodile branch March 13, 2026 02:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants