Files
vscode/extensions/copilot/src/platform
Ulugbek Abdullaev 0035fb2e7e nes: track originating model patch for streamed edits (#322573)
PR #322438 allowed splitting one model-sent diff-patch into multiple
LineReplacements, breaking the invariant that the Nth shown edit
corresponded to the Nth model patch (progressive ghost-text reveal
already broke it too). As a result, telemetry could no longer attribute
a served edit back to the model patch it came from.

Stamp a 0-based `patchIndex` on each Patch in extractEdits, thread it
through the streamed-edit -> cache -> telemetry pipeline, and emit a new
`sourcePatchIndex` telemetry measurement. All fragments produced from the
same patch (diff splitting or ghost-text early + continuation) share the
index. The field is optional since the edit-window and INSERT response
formats have no patch structure.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-23 20:49:29 +02:00
..