Commit Graph

111 Commits

Author SHA1 Message Date
Bhavya U 256a46f76a Re-enable multifile-edit-claude stests with claude-sonnet-4.5 (#316126)
Fixes #315940
2026-05-12 23:07:56 +00:00
Bhavya U 6b5334c5f4 feat: make stream a caller-controlled passthrough in Messages API (#311003)
* feat: make stream a caller-controlled passthrough in Messages API

Allow callers to set stream: false via requestOptions instead of
hardcoding stream: true. Add non-streaming response handler for the
Anthropic Messages API that parses single JSON responses.

- createMessagesRequestBody: stream: true → options.requestOptions?.stream ?? true
- preparePostOptions: stream: true as default before spread (callers can override)
- processResponseFromMessagesEndpoint: auto-detect via Content-Type header
- processNonStreamingResponseFromMessagesEndpoint: new handler for JSON responses
  with tool call support in finishedCb delta, defensive parsing, cache-token
  consistency warning, unknown block type logging
- Remove stale 'stream not respected' comment from fetch.ts
- Remove stream: false from agentIntent.ts inline summarization
- 10 new tests for non-streaming handler

* fix: add telemetry parity for non-streaming path and bump cache salt

* regenerate simulation cache for review-inline tests

* Regenerate simulation cache after rebase

* Temporarily disable multifile-edit-claude variant (#315940)

claude-3.5-sonnet returns model_not_supported from the endpoint, breaking
simulation cache regen. Re-enable when the test is updated to use a
currently-supported Claude model.

* Fix terminal strict-mode crash on empty suggestions + update baseline

- terminal.stest.ts: guard strict-mode `ok()` predicate so when the model
  returns no code block, the test fails cleanly with the existing message
  instead of crashing with 'Cannot read properties of undefined (reading match)'.
  Also drop the stale commented-out debug block.
- baseline.json: refresh scores (68.01 -> 68.69) and drop the 14 entries for
  the disabled multifile-edit-claude variant (see #315940).
- Remove now-orphaned multifile-edit-claude-panel.json outcome file.

* Apply CI-observed score improvements for cpp inline scenarios

CI on Linux scores 4 cpp InlineChatIntent scenarios higher than my local
macOS run does (likely platform-specific line-ending/whitespace normalization
in the cpp grader). Update baseline.json to match the Linux scores:

- edit-InlineChatIntent [inline] [cpp] - edit for cpp:               5 -> 9
- edit-InlineChatIntent [inline] [cpp] - edit for macro:             0 -> 2
- generate-InlineChatIntent [inline] [cpp] - cpp code generation:    3 -> 10
- generate-InlineChatIntent [inline] [cpp] - templated code gen:     0 -> 10

Overall score: 68.69 -> 68.86.

* Populate cpp diagnostic cache via Docker for cross-platform parity

The earlier rebase cache regen produced new LLM responses for the cpp
inline tests but failed to populate the clang diagnostic provider cache
for those new inputs, because clang detection on macOS is broken (Apple
clang prints '-v' output to stderr, but findIfInstalled only checks
stdout) and Docker wasn't running. As a result the cpp diagnostic cache
was missing entries for the new LLM responses, and CI re-ran clang live
on each platform with diverging results:

  - Linux CI:   clang available, scored highest (9, 2, 10, 10)
  - Windows CI: no clang, errored out (5, 0, 10, 10 with worsening)
  - macOS:      Apple clang misdetected as missing, Docker off, errored

This commit:

  1. Bumps CLANG_DIAGNOSTICS_PROVIDER_CACHE_SALT 5 -> 6 to invalidate
     any contaminated entries.
  2. Adds two new cache layers populated by running cpp tests via Docker
     (using the mcr.microsoft.com/devcontainers/cpp image, same Linux
     clang as CI). All 14 cpp scenarios now produce deterministic,
     platform-independent diagnostic results when read from cache.

Verified with --require-cache: all cpp scenarios pass without invoking
clang/docker at runtime.
2026-05-11 21:59:58 -07:00
Johannes Rieken c76e907f98 make v2 default mode for inline chat (#313184)
* remove old inline chat from extension

* refactor: remove deprecated inline chat V2 configuration and related checks

Co-authored-by: Copilot <copilot@github.com>

* refactor: update context keys for inline chat and clean up unused variables

* address copilot review: fix typo and rename forInlineAndInlineChatIntent

---------

Co-authored-by: Copilot <copilot@github.com>
2026-04-29 12:50:58 +02:00
Johannes d314fbc8c7 stests 2026-04-24 09:34:51 +02:00
Johannes e5bfe28ae3 copilot: remove InlineDocIntent and /doc command 2026-04-23 17:43:05 +02:00
Matt Bierner 8a370f0f75 move under ext src 2026-04-09 13:31:06 -07:00
Matt Bierner ae4af364ad Fix a few subprojects 2026-04-09 11:39:04 -07:00
Johannes Rieken 9ac60c7956 inline chat: drop EditFile tool when better edit tools are available (#4479)
* inline chat: drop EditFile tool when better edit tools are available

Fixes https://github.com/microsoft/vscode/issues/302062

* stest

* stest
2026-03-18 11:20:28 +00:00
Johannes Rieken 1554132d4b Better inline chat exit (#4361)
* Refactor inline chat exit tool handling and update prompt instructions for clarity

re https://github.com/microsoft/vscode/issues/296601#top

* stests

* stests...
2026-03-11 21:31:24 +00:00
Connor Peet 7e7c1a6cc7 tools: add binary file support with hexdump display (#4331)
* tools: add binary file support with hexdump display

Adds support for reading and displaying binary files in the read file tool
with a hexdump-formatted view. This enables better handling of binary content
in the IDE context without attempting to interpret them as text.

- Adds hexdump utility to format binary data in a readable hex/ASCII view
- Extends readFileTool to detect binary files and provide formatted output
- Adds binaryFileHexdump prompt component for displaying binary content
- Integrates binary file variable support in file variable display
- Updates test fixtures with binary file handling scenarios

Fixes https://github.com/microsoft/vscode/issues/284178
Fixes https://github.com/microsoft/vscode/issues/299973

(Commit message generated by Copilot)

* pr comments

* baseline update

* baseline update
2026-03-10 21:49:13 +00:00
Giuseppe Cianci dd5c74f230 Simulation workbench: show error states and improve rerun UX (#4319)
* fix simulate task for windows

* fix ui for errors

* update

* address copilot review
2026-03-10 17:22:16 +00:00
Logan Ramos 62215a8a23 Remove hard coded gpt 4.1 in favor of copilot base (#4124)
* Remove hard coded gpt 4.1 in favor of copilot base

* Update simulator cache
2026-03-02 22:05:28 +00:00
Johannes Rieken ab69ce9740 inline chat: fix tool call round ordering in prompt and surface edit … (#4102)
* inline chat: fix tool call round ordering in prompt and surface edit failures

* stests
2026-03-02 10:48:47 +00:00
Rob Lourens c5daa20856 Remove edits2 setting/participant (#4099)
* Remove edits2 setting/participant

* Remove EditTestStrategy.Edits2 from simulation tests (Written by Copilot)
2026-03-02 06:20:19 +00:00
Johannes Rieken 1265160099 Inline chat v2 should use readTool when dealing with large files (#3990)
* Inline chat: support large-file read rounds and prompt read history

* stests
2026-02-25 12:15:07 +00:00
Harald Kirschner 7aa17fc25e fix: align promptCategorization.requestId with panel.request for telemetry joins (#3874)
Co-authored-by: Harald Kirschner <digitarald@gmail.com>
2026-02-19 23:57:48 +00:00
Ulugbek Abdullaev 7d728b836e swb: fix support for external NES stests for windows & "run test once" (#3768)
* swb: fix: make external NES stest running windows-compatible

* swb: support running a single external test

* address ccr
2026-02-16 15:21:10 +00:00
Ulugbek Abdullaev 0c77656331 nes: feat: more diff merging strategies (#3763)
also fix that two adjacent line changes would result in two diff hunks
2026-02-16 11:15:45 +00:00
Rob Lourens a4ffdcf03b Sync chatParticipantPrivate.d.ts with vscode (#3734)
* Sync chatParticipantPrivate.d.ts

* Sync ChatRequestEditorData with vscode
2026-02-13 21:07:31 +00:00
Ulugbek Abdullaev c92f112bd5 swb: support external NES tests (#3719) 2026-02-13 14:18:05 +00:00
Ulugbek Abdullaev 5e0ca23866 nes: flush copilot-nes-oct cache and run external nes stests (#3605)
* nes: flush copilot-nes-oct cache and run external nes stests

* update nes stests
2026-02-10 13:45:19 +00:00
Rob Lourens e5cd86beeb Rename /summarize to /compact, add optional extra instructions (#3556)
* Rename /summarize to /compact, add optional extra instructions

* Update simulation baseline
2026-02-08 18:11:03 +00:00
Rob Lourens 84b8b46bd5 Add session transcript service for hooks (#3545)
* Add session transcript service for hooks

Implement JSONL-based session transcript service that records
conversation turns, tool executions, and assistant messages for
hook consumers.

Key changes:
- New ISessionTranscriptService interface and SessionTranscriptService
  implementation with buffered writes and automatic old transcript cleanup
- Integrate transcript logging into tool calling loop: user messages,
  assistant messages, tool execution start/complete, turn boundaries
- Auto-flush transcript and inject transcript_path into hook input
- Race flush with 500ms timeout to avoid blocking hook execution
- Gate transcript creation on ChatRequest.hasHooksEnabled
- Include copilotVersion and vscodeVersion in session.start entry
- Add timestamp to IToolCallRound for transcript timing
- Add hasHooksEnabled to ChatRequest interface and all implementors

* Fixes
2026-02-07 02:04:46 +00:00
Matt Bierner 34b17f117d Remove @workspace chat participant (#3492)
* Remove `@workspace` chat participant

For https://github.com/microsoft/vscode/issues/292972

Removes the `@workspace` chat participant since this is now an outdated (and confusing) way to use code search. For now we'll keep the commands but I've moved them under the default agent instead

* Updating tests too and fixing some references
2026-02-06 00:21:09 +00:00
Connor Peet ba2e206efe tools: cleanup unused pause logic (#3488)
We removed the 'pause' feature back in ~June, cleanup logic we still had
around it. This removes:

- The PauseController class which was no longer being used
- onPaused event parameters from chat participant, request, and intent
  handlers
- Pause-related event listening and stream pausing logic
- Simplified throwIfCancelled to be synchronous since it no longer needs
  to wait for pause resumption

(Commit message generated by Copilot)
2026-02-05 18:24:07 +00:00
Connor Peet 8ca2807e66 chat: wire up yieldrequested for steering messages (#3473)
* chat: wire up yieldrequested for steering messages

Allows the client to do a 'soft cancel' after a tool call happens before returning back to the model, or before the next turn.

* fix compile
2026-02-05 16:05:57 +00:00
Karthik Nadig 86e5f95490 Add question functionality and related types for chat interactions (#3157)
* Add question carousel functionality and related types for chat interactions

* feat: enhance logging for question carousel processing and answer conversion

* feat: enhance answer processing in AskQuestionsTool to support freeform text input

* cleanup: remove unused AskQuestionResult type from IQuestionAnswer

* clenaup: restore package.json

* feat: enhance AskQuestionsTool to handle no stream scenario and improve carousel answer conversion
2026-01-26 19:23:30 +00:00
Ulugbek Abdullaev 311d7fab8b update to latest vscode sources (#3118) 2026-01-26 09:52:58 +00:00
Johannes Rieken e8e9b03ba7 Tweak prompt selection and also remind model to do all edits in a single tool call (#3125)
* Tweak prompt selection and also remind model to do all edits in a single tool call

* (fix) correct tool name

* stest

* more stest drama
2026-01-26 08:36:17 +00:00
Johannes Rieken 1b8308f1fd Inline chat handles empty selections explicitly (#2535)
* handle empty selection better in inline chat

* stests

* add unit tests

* Update src/extension/prompts/node/inline/inlineChat2Prompt.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* stests

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-11 13:50:17 +00:00
Ulugbek Abdullaev 3417fc6d7c update cache (#2533) 2025-12-11 10:36:12 +00:00
Matt Bierner 3c8134184b Enable no-unexternalized-strings in repo (#2448)
Enables the same `no-unexternalized-strings` with have in `vscode` in this repo. This make sure we have a more consistent style across repos and when generating edits
2025-12-05 18:45:12 +00:00
Johannes Rieken 02d7754061 * drive inline chat feedback telemetry from CopilotInteractiveEditorResponse (#2435)
* `CopilotInteractiveEditorResponse.kind` is always 'ok' -> remove it

fixes https://github.com/microsoft/vscode/issues/280959
2025-12-05 13:26:45 +00:00
Ulugbek Abdullaev aee2abe2e1 nes: joint: don't enforce cache delay if document hasn't changed (#2409) 2025-12-04 22:13:16 +00:00
Johannes Rieken 36f0ab1f6f inline chat fixes (#2348)
* make sure the exit-tool is called when nothing else has been called

fixes https://github.com/microsoft/vscode/issues/280775

* tweak inline prompt for better prefix-caching

https://github.com/microsoft/vscode-internalbacklog/issues/6337
2025-12-03 10:14:20 +00:00
Ulugbek Abdullaev 3c78ed81dd nes: support /models on proxy and model picker (#2325) 2025-12-02 14:14:53 +00:00
Johannes Rieken 0231290715 keep intent detection for inline v1 intact (#2264) 2025-11-28 14:29:05 +00:00
Ulugbek Abdullaev 71803ce30f nes: support jump-to label (#2248)
* nes: update to latest core API for completions

* nes: support jump-to
2025-11-27 18:41:52 +00:00
Johannes Rieken bfc3fe5285 check edit tool results for errors and try again if editing failed (#2246)
* check edit tool results for errors and try again if editing failed

https://github.com/microsoft/vscode/issues/275056

* Update src/extension/prompts/node/inline/inlineChat2Prompt.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix prompt

* update-baseline

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-27 17:09:20 +00:00
Johannes Rieken a951ba62d1 fix https://github.com/microsoft/vscode/issues/277850 (#2079) 2025-11-19 15:17:31 +00:00
Johannes Rieken 34393c52c7 Always use github.copilot.editingSessionEditor, enable slash-command based on v2-config (#2060)
* Always use `github.copilot.editingSessionEditor`, enable slash-command based on v2-config

This makes all requests go to the `InlineChatIntent` and it decides (based on the v2-config) if it uses the "old world" for making inline chat requests happen

* re-run tests
2025-11-18 16:57:12 +00:00
Sandeep Somavarapu fedde4f1f1 clean up: (#2040)
* clean up:
- simplify namespaces
- simplify defining settings

* fix unused configs
2025-11-17 14:32:52 +00:00
Johannes Rieken a3a3829ee3 remove temporal context experiment (#1957)
fixes https://github.com/microsoft/vscode-copilot/issues/17115
fixes https://github.com/microsoft/vscode-copilot/issues/12756
fixes https://github.com/microsoft/vscode-copilot/issues/11674
2025-11-12 16:52:08 +00:00
Johannes Rieken 72dc56bdf3 Use cacheBreakpoint for inline chat prompt (#1954) 2025-11-12 16:15:07 +00:00
Don Jayamanne d0f16d6dc2 Remove zeromq and related unwanted notebook execution tests (#1941) 2025-11-12 04:31:49 +00:00
Ulugbek Abdullaev 1bd445ec60 update cache (#1822) 2025-11-07 10:39:59 +00:00
Ulugbek Abdullaev 4e4997c6d8 update cache (#1824) 2025-11-06 14:04:19 +00:00
Ulugbek Abdullaev f082551888 nes: remove old settings to configure model (#1823) 2025-11-06 14:04:18 +00:00
Ladislau Szomoru 2c92092e40 Git - add repository/branch name to the commit message generation context (#1756) 2025-11-02 19:26:50 +00:00
Ulugbek Abdullaev fe96b6d014 update cache (#1705) 2025-10-30 13:09:03 +00:00