Commit Graph

6420 Commits

Author SHA1 Message Date
Rob Lourens
77c1d46b28 Merge remote-tracking branch 'origin/main' into connor4312/agent-host-server 2026-03-17 15:07:52 -07:00
Robo
8f136419bb chore: disallow node version untested for development (#302550)
* chore: disallow node version untested for development

* chore: wording feedback

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>
2026-03-17 21:00:39 +00:00
Rob Lourens
1c035e8297 Merge branch 'main' into connor4312/agent-host-server 2026-03-17 13:56:32 -07:00
João Moreno
c58fd111b2 fix: rename pipeline (#302543) 2026-03-17 20:37:18 +00:00
Rob Lourens
6076e772e8 Clean up dead code 2026-03-17 11:47:04 -07:00
Connor Peet
927a0932fc fix 2026-03-17 11:36:56 -07:00
Rob Lourens
2944e51725 Copilot using vscode's ripgrep (#302323) 2026-03-17 17:57:16 +00:00
João Moreno
19daf4d536 feat: rename pipeline and fix esm script (#302466)
Co-authored-by: Copilot <copilot@github.com>
2026-03-17 16:06:38 +00:00
João Moreno
e3b4bdb925 allow terrapin checks to by manually triggered and report results back to GitHub (#302451)
* initial terrapin check poc

* bump terrapin timeout, remove trigger

* allow terrapin checks to by manually triggered and report results back to GitHub

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

---------

Co-authored-by: Copilot <copilot@github.com>
2026-03-17 14:34:34 +00:00
João Moreno
817d225857 Change Terrapin checks to be manual dispatches, increase timeouts (#302398)
* initial terrapin check poc

* bump terrapin timeout, remove trigger
2026-03-17 14:12:56 +00:00
Robo
f8fd37feb6 chore: bump electron@39.8.2 (#302204) 2026-03-17 07:54:12 +00:00
Robo
555f6469c6 ci: fix universal build for fs-copyfile usage in git extension (#302332) 2026-03-17 07:45:44 +01:00
Josh Spicer
2a5a1757fd build(next): include sessions built-in skills in desktop resources (#302297)
Enhance AI Customization: Add support for plugin skills in data source
2026-03-16 19:06:19 -07:00
Rob Lourens
3da382383e Merge remote-tracking branch 'origin/main' into connor4312/agent-host-server 2026-03-16 16:25:07 -07:00
Rob Lourens
98f15b55ea Implement agentHost process (#296627)
* agent host init

* Agent host: Copilot SDK integration with chat UI

* Agent host: direct MessagePort, logging, SDK wrapper, env fix

* Refactoring and cleanup

* Copilot-authored message: Agent-host tool rendering, protocol, and session fixes

Tool invocation rendering:
- Emit tool_start/tool_complete as ChatToolInvocation (not progressMessage)
- Shell tools (bash/powershell) render as terminal command blocks with
  IChatTerminalToolInvocationData, output, and exit codes
- Non-shell tools render via invocationMessage/pastTenseMessage (markdown)
- Filter out report_intent (hidden internal tool)

Agent-agnostic protocol:
- IPC events carry display-ready fields (displayName, invocationMessage,
  pastTenseMessage, toolInput, toolOutput, toolKind, language)
- All Copilot CLI-specific logic in copilotToolDisplay.ts with typed
  interfaces for known tools (CopilotToolName enum, parameter types)
- Renderer never references specific SDK tool names

Session fixes:
- Resumed sessions show tool invocations in history (getSessionMessages
  now returns tool events alongside messages)
- Fixed 'already has a pending request' on resumed sessions by
  conditionally providing interruptActiveResponseCallback
- Fixed event filtering for resumed sessions (sessionId override in
  _trackSession)

Documentation:
- Split parity.md into design.md (decisions) and backlog.md (tasks)
- Updated architecture.md, sessions.md with cross-references
- Added maintenance notes to all docs

* Copilot-authored message: Model picker, session class, DI and test cleanup

* Cleanups

* stuff

* add diagram

* Add claude agent

* Clean up

* Copy some build script changes from #295817

* Simplify

* Update docs

* Register agent-host via chatSessions contribution API, reduce peripheral diff

* Cleanup

* Don't ship stuff in stable

* Dynamic agent discovery via listAgents() IPC

Replace hardcoded per-provider contributions with a single
AgentHostContribution that discovers available agents from the
agent host process at startup. Each IAgent backend now exposes
an IAgentDescriptor with display metadata and auth requirements.

- Add IAgentDescriptor interface and listAgents() to IPC contract
- CopilotAgent/ClaudeAgent return descriptors via getDescriptor()
- Single AgentHostContribution discovers + registers dynamically
- Remove agentHostConstants.ts (no more hardcoded session types)
- AgentHostSessionListController/LMProvider take params instead
- Rename AgentSessionProviders.AgentHost -> AgentHostCopilot
- Update architecture.md, sessions.md, backlog.md

(Written by Copilot)

* Fix review findings: proxy, disposal, filtering, tests

- Add listAgents() forwarding to AgentHostServiceClient
- Guard async discovery against disposal race
- Add provider field to IAgentModelInfo for per-provider filtering
- Filter models and sessions by provider in LM provider and list
  controller
- Update tests for new dynamic API and agent-host-copilot scheme

(Written by Copilot)

* Use DI for AgentHostLanguageModelProvider

(Written by Copilot)

* Strip @img/sharp native binaries from builds

sharp is a transitive dependency of the Claude Agent SDK used for
image processing. Its native .node binaries cause dpkg-shlibdeps
errors during Debian packaging due to $ORIGIN RPATH references.
Strip all @img/sharp-* platform packages since the agent host
doesn't need image processing at runtime.

(Written by Copilot)

* Strip Claude SDK vendored ripgrep binaries

The Claude Agent SDK bundles ripgrep binaries for all platforms
under vendor/ripgrep/. Wrong-architecture binaries cause macOS
Mach-O verification to fail. Strip them entirely via .moduleignore
(VS Code has its own ripgrep) and add to verify-macho skip list.

(Written by Copilot)

* Add tests for AgentSession, AgentService dispatcher, and workbench agent host components

(Written by Copilot)

* Add trace logging, IPC output channel, tool permissions, and attachment context

- Add Agent Host IPC output channel (only registered at trace log level) that
  logs all IPC method calls, results, and progress events with full JSON payloads
- Add trace-level logging in AgentService dispatcher for all method calls
- Add trace-level logging in session handler for all progress events and session
  resolution
- Wire up onPermissionRequest handler on CopilotClient.createSession and
  resumeSession to auto-approve tool permission requests
- Add IAgentAttachment type to IPC contract and thread attachments from chat
  variables (file, directory, selection) through sendMessage to the Copilot SDK

(Written by Copilot)

* Add tests for attachment context conversion and threading

(Written by Copilot)

* Add gap analysis docs for Copilot and Claude SDK implementations

(Written by Copilot)

* Sanitize env vars for Copilot CLI subprocess

Strip VSCODE_*, ELECTRON_* (except ELECTRON_RUN_AS_NODE), NODE_OPTIONS, and
other debug-related env vars that can interfere with the Node.js process the
SDK spawns. Matches the env sanitization from the extension implementation.
Also set useStdio and autoStart for proper CLI communication.

(Written by Copilot)

* Add error, usage, and title_changed event types to IPC contract

Add IAgentErrorEvent, IAgentUsageEvent, and IAgentTitleChangedEvent to the
progress event union. Wire up session.error and assistant.usage events from
the Copilot SDK to fire as IPC events instead of only logging. Handle error
events in the renderer session handler by rendering the error message. Usage
and title_changed events are logged at trace level.

(Written by Copilot)

* Add abortSession IPC method for proper cancellation

Add abortSession(session) to the IPC contract, implemented across AgentService,
CopilotAgent (calls session.abort()), ClaudeAgent (no-op, uses AbortController),
and the renderer proxy. Wire up cancellation in the session handler to call
abortSession before finishing, so the SDK actually stops processing.

(Written by Copilot)

* Address reviewer feedback: error finishes request, Claude abort, tests

- Error events now call finish() so the request doesn't hang if the SDK
  doesn't send idle after an error
- ClaudeAgent.abortSession calls ClaudeSession.abort() which signals the
  AbortController and creates a new one for future turns
- Add test: cancellation calls abortSession on the agent host service
- Add test: error event renders message and finishes the request
- Remove stale TODO in interruptActiveResponseCallback
- Use timeout() helper instead of raw setTimeout in test
- Update gap docs to reflect completed work

(Written by Copilot)

* Add permission request IPC round-trip (Written by Copilot)

* Remove Claude agent from agent-host process

Strip the Claude Agent SDK integration from the agent-host utility process
to focus on the Copilot SDK path.

- Delete src/vs/platform/agent/node/claude/ (claudeAgent, claudeSession, claudeToolDisplay)
- Remove @anthropic-ai/claude-agent-sdk from package.json
- Remove AgentHostClaude enum member and all switch cases
- Remove Claude command registration in electron-browser chat.contribution
- Clean up build scripts (.moduleignore, verify-macho, gulpfile.vscode)
- Narrow AgentProvider type to just 'copilot'
- Update tests and documentation

(Written by Copilot)

* Wire up permission confirmation UI with ChatToolInvocation (Written by Copilot)

* Fix reviewer feedback: safe permission serialization, deny on abort/dispose (Written by Copilot)

* Forward reasoning events as thinking blocks (Written by Copilot)

* Pass workspace folder as workingDirectory to Copilot SDK (Written by Copilot)

* Store and pass workingDirectory on session resume, update gap docs (Written by Copilot)

* Fix permission rendering, session-scoped permissions, and test gaps (Written by Copilot)

* Auto-approve read permissions inside workspace folder (Written by Copilot)

* Move read auto-approve into CopilotAgent where permission policy belongs (Written by Copilot)

* Update gap docs (Written by Copilot)

* Use log language for IPC output channel, add trace prefix (Written by Copilot)

* Add tool rendering gaps to docs (Written by Copilot)

* Stringify URIs in IPC output channel for readability (Written by Copilot)

* Fix IPC output channel: use log languageId with non-log channel for proper append + syntax highlighting (Written by Copilot)

* Fix build errors: add URI import, fix test mock types (Written by Copilot)

* Don't localize agent host provider strings (Written by Copilot)

* Remove claude-agent-sdk from eslint allowed imports (Written by Copilot)

* fix test

* initial thoughts

* Rename folder to agentHost

* Fix paths

* Fixes

* Fixes for copilot

* Fix moduleignore

* first working protocol version

align more closely with protocol

json rpc and some gaps

* cleanup

* Fix copilot pty.node packaging

* Fix test

* prebuild packaging

* Agenthost server fixes

* Update monaco.d.ts

* Update docs

* Fixes

* Build fix

* Fix build issues

* reduce duplication in side effecting code

* fix model switching not working

* reduce mock duplication

* Build fixes

* Copy vscode's node.pty

* And ripgrep

* And thsi

* Ripgrep goes to non-SDK

* Skip copy for stable build

* Remove outdated script

* Build fixes for asar

* fix

* Add some logging

* Fix for windows

* Fix

* Logs

* build: add glob diagnostic for copyCopilotNativeDeps

* build: check both node_modules/ and .asar.unpacked/ for source binaries

* Fix

* Remove excalidraw

---------

Co-authored-by: Connor Peet <connor@peet.io>
Co-authored-by: Connor Peet <copeet@microsoft.com>
2026-03-16 15:33:31 -07:00
Robo
c3eb7f8453 chore: bump electron@39.8.1 (#302053)
* chore: bump electron@39.8.1

* chore: update node.js build

* chore: bump distro

* chore: bump .nvmrc
2026-03-16 14:51:48 +00:00
Ladislau Szomoru
c3b9417517 Git - second attempt to adopt the @vscode/fs-copyfile package (#301443)
* Reapply "Git - adopt the new package to use copy-on-write for the worktree include files (#299583)" (#300448)

This reverts commit c56c7bc071.

* Attempt to fix tests

* Fix build

* build: copy node_modules into extension bundle

* Regenerate lock file

---------

Co-authored-by: deepak1556 <hop2deep@gmail.com>
2026-03-16 14:14:06 +00:00
João Moreno
95e71c6873 fix: enhance release approval condition to include main and release branches (#302057)
Co-authored-by: Copilot <copilot@github.com>
2026-03-16 11:50:35 +00:00
João Moreno
4bf76cd10b feat: add job to trigger insider builds for release branches (#302047)
Co-authored-by: Copilot <copilot@github.com>
2026-03-16 12:20:40 +01:00
Robo
50334e7e1d chore: revert compiled assets for macos 26 icon support (#302029) 2026-03-16 11:59:06 +01:00
João Moreno
a7b8934257 feat: automatically build release branches (#301991)
Co-authored-by: Copilot <copilot@github.com>
2026-03-16 10:11:06 +01:00
Josh Spicer
2c43738efa sessions: built-in skills (#301607)
* sessions: add built-in skills infrastructure

Add a 'built-in skills' concept mirroring the existing 'built-in prompts'
pattern, so that skills bundled with the Sessions app are always available.

- Create src/vs/sessions/skills/ directory for bundled SKILL.md files
- Bundle vs/sessions/skills/**/SKILL.md in build config
- AgenticPromptsService: discover and parse built-in skills from the
  bundled directory, override findAgentSkills() to merge them at lowest
  priority (user/workspace skills override by name), extend listPromptFiles
  and listPromptFilesForStorage for skill type
- Tree view: handle BUILTIN_STORAGE group for skills category

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

* sessions: add built-in 'update-skills' skill

First built-in skill that guides the agent to capture major repository
learnings by creating or updating skills and instructions. Triggered
when the user says 'learn!' or when significant reusable knowledge is
discovered during a session.

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

* sessions: support edit-and-save-to-override for built-in skills

Extend the built-in prompt save-to-override flow to also work for
built-in skills. When editing a built-in skill, users can save it to
workspace or user location, which overrides the built-in version.

- Gate the in-memory editing session on both prompt and skill types
- Resolve save target directories using the actual prompt type
- Preserve skill directory structure ({name}/SKILL.md) when saving
- Generalize UI labels from 'prompt override' to 'override'

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

* sessions: address PR review feedback for built-in skills

- Sanitize built-in skill name/description (strip XML tags, truncate)
  to match the same safety applied to other skill sources
- Fix JSDoc: all sources override built-ins, not just user/workspace
- Remove unnecessary 'as unknown as PromptsStorage' cast in tree view

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

* sessions: refine editor options types for accessibility and font settings

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-13 16:03:37 -07:00
João Moreno
ac40642c8e refactor: remove rollout duration for insider builds in release process (#301496) 2026-03-13 13:58:56 +00:00
Robo
20a1637cef fix: repair folder context menu when only legacy file context menu is present (#300752)
* fix: repair folder context menu when only legacy file context menu is present

* chore: restore folder menu in installer wizard
2026-03-13 21:36:52 +09:00
Rob Lourens
87b808097d Merge remote-tracking branch 'origin/roblou/agent-host' into connor4312/agent-host-server 2026-03-12 21:19:14 -07:00
Rob Lourens
5c16c31f88 Connect to remote agent hosts via setting chat.remoteAgentHosts (#301224)
* Copy vscode's node.pty

* And ripgrep

* And thsi

* Connect to remote agent hosts via setting chat.remoteAgentHosts

* This

* Fix

* Cleanup

* Rearrange, add unit tests
2026-03-12 21:14:15 -07:00
Rob Lourens
354c9140c6 Skip copy for stable build 2026-03-12 19:31:36 -07:00
Rob Lourens
fa411a7cd1 Ripgrep goes to non-SDK 2026-03-12 18:28:11 -07:00
Rob Lourens
1617f8d42d And thsi 2026-03-12 16:51:56 -07:00
Rob Lourens
f4a66a7543 And ripgrep 2026-03-12 16:49:35 -07:00
Rob Lourens
14160da866 Copy vscode's node.pty 2026-03-12 16:43:05 -07:00
Connor Peet
813d943aeb scary--; hacky++; 2026-03-12 16:20:56 -07:00
Rob Lourens
6c405bfc9f Build fixes 2026-03-12 16:02:57 -07:00
Rob Lourens
eea22c1bcf Fix build issues 2026-03-12 14:27:28 -07:00
Rob Lourens
aff48ba8fb Build fix 2026-03-12 13:33:09 -07:00
Raymond Zhao
38f689e11d chore: align install steps (#301147) 2026-03-12 10:36:19 -07:00
Rob Lourens
dffac9c6ba Merge remote-tracking branch 'origin/main' into roblou/agent-host 2026-03-12 10:07:40 -07:00
Rob Lourens
cb51cb4ac3 prebuild packaging 2026-03-12 09:55:40 -07:00
Rob Lourens
cb1bf5f351 Fix copilot pty.node packaging 2026-03-12 09:11:36 -07:00
Robo
d666fe6572 feat: add assets for macOS 26 icon support (#300901) 2026-03-12 05:32:01 +00:00
Robo
85b156f976 fix: move versioned folder check closer to the package task (#300685) 2026-03-11 21:51:42 -07:00
Peng Lyu
b79bcf7011 Merge pull request #300983 from microsoft/rebornix/hollow-tarantula-image
feat: add image carousel
2026-03-11 20:39:36 -07:00
Peng Lyu
c3d734644a feat: add image carousel project to i18n resources 2026-03-11 19:22:50 -07:00
Matt Bierner
cfff60f09d Merge pull request #300860 from mjbvz/dev/mjbvz/heavy-swallow
Re-remove webpack (again again)
2026-03-11 18:14:40 -07:00
Tyler James Leonhardt
d582a1590b Allow vscode-sessions strings in the main bundle (#300944)
It seems like the sessions experience _can_ run in the VS Code world, so we actually do need these strings.
2026-03-11 17:46:40 -07:00
Rob Lourens
076b448ec0 Merge remote-tracking branch 'origin/main' into roblou/agent-host 2026-03-11 16:03:31 -07:00
Henning Dieterichs
5d56633a57 updates component explorer 2026-03-11 22:30:41 +01:00
Tyler James Leonhardt
2f42f2e800 Add sessions support to translation resources and update related logic (#300889)
* Add sessions support to translation resources and update related logic

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

* update to track new format of import

* fix failures
2026-03-11 20:38:06 +00:00
Rob Lourens
f1239c83e4 Fix moduleignore 2026-03-11 12:34:58 -07:00
Matt Bierner
7a090df6c7 Re-remove webpack (again again)
This reverts commit 1d31c3ce40.
2026-03-11 10:46:45 -07:00