Skip to content
This repository was archived by the owner on May 20, 2026. It is now read-only.

add isSystemInitiated and relevant changes#4944

Merged
meganrogge merged 11 commits into
mainfrom
merogge/is-system-initiated
Apr 3, 2026
Merged

add isSystemInitiated and relevant changes#4944
meganrogge merged 11 commits into
mainfrom
merogge/is-system-initiated

Conversation

@meganrogge

@meganrogge meganrogge commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@meganrogge meganrogge requested review from Copilot and roblourens April 2, 2026 18:49
@meganrogge meganrogge self-assigned this Apr 2, 2026
@meganrogge meganrogge added this to the 1.115.0 milestone Apr 2, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds a new “system-initiated” classification to chat requests so the extension can (a) mark requests that were triggered automatically by VS Code, (b) propagate that through prompt construction + fetch paths, and (c) emit distinct telemetry / interaction headers (for downstream billing/analytics differentiation).

Changes:

  • Introduces isSystemInitiated on the (proposed) VS Code ChatRequest shape and propagates it into the agent prompt layer.
  • Adds ISystemInitiatedRequestOptions and threads it through networking/fetcher APIs to set a distinct X-Interaction-Type.
  • Emits isSystemInitiated in panel telemetry and adjusts “userInitiatedRequest” calculation to exclude system-initiated requests.

Reviewed changes

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

Show a summary per file
File Description
src/platform/networking/common/networking.ts Extends request-kind options and maps system-initiated to conversation-system-initiated interaction header.
src/extension/vscode.proposed.chatParticipantPrivate.d.ts Adds isSystemInitiated?: boolean to the proposed ChatRequest API docs.
src/extension/prompts/node/agent/agentPrompt.tsx Plumbs isSystemInitiated into AgentUserMessage and skips wrapping/context for system-initiated prompts.
src/extension/prompt/node/defaultIntentRequestHandler.ts Sets telemetry subtype + request kind options when the request is system-initiated.
src/extension/prompt/node/chatParticipantTelemetry.ts Adds isSystemInitiated property to panel.request telemetry payload/GDPR schema.
src/extension/prompt/node/chatMLFetcher.ts Extends requestKindOptions typing and maps system-initiated to interaction type for WebSocket fetch path.
src/extension/intents/node/toolCallingLoop.ts Ensures userInitiatedRequest is false for system-initiated requests.

Comment thread src/platform/networking/common/networking.ts Outdated
Comment thread src/extension/prompt/node/chatMLFetcher.ts Outdated
Comment thread src/extension/prompts/node/agent/agentPrompt.tsx
Comment thread src/platform/networking/common/networking.ts Outdated
Comment thread src/extension/prompt/node/defaultIntentRequestHandler.ts
@meganrogge meganrogge enabled auto-merge April 2, 2026 22:06
dmitrivMS
dmitrivMS previously approved these changes Apr 2, 2026
dmitrivMS
dmitrivMS previously approved these changes Apr 2, 2026
dmitrivMS
dmitrivMS previously approved these changes Apr 2, 2026
mjbvz
mjbvz previously approved these changes Apr 2, 2026
@meganrogge meganrogge added this pull request to the merge queue Apr 3, 2026
Merged via the queue into main with commit 1a089d9 Apr 3, 2026
19 checks passed
@meganrogge meganrogge deleted the merogge/is-system-initiated branch April 3, 2026 00:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants