Files
vscode/src/vs
800753c844 sessions: add send_message and get_session_context tools (#325139)
* Add send_message server tool

Adds a send_message tool that starts a new turn on an existing session or chat,
reusing the same startPrompt path create_session/create_chat use to deliver their
first message. Accepts a list_sessions URI or an agent-host-session:// link; a
create_chat link (with ?chat=) targets that specific peer chat, otherwise the
session's default chat. Requires confirmation, refuses messaging the current chat
channel (self-loop guard), and has a process-wide fan-out backstop. Renders the
same 'Open Session' pill (conversation icon when chat-scoped) and is unpinned from
the thinking group like the other session tools.

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

* Add isSendMessageTool unit test for prefix matching

Addresses PR review: cover the bare and mcp__server__-prefixed name paths for
isSendMessageTool, mirroring the existing isCreateSessionTool/isCreateChatTool
tests.

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

* sessions: add get_session_context tool + list_sessions single-session lookup (#325158)

Add get_session_context tool and list_sessions single-session lookup

Adds a read-only get_session_context server tool that returns a compacted
transcript of an existing session/chat's recent turns, read directly from live
chat state. Three fidelity levels: summary (per-turn message + short reply
gist), digest (full reply text + tool-call names), full (+ tool-call inputs);
bounded by transcriptLimit (default 10, max 50) with hasMoreHistory/truncated
flags and the in-progress turn included. Deterministic only, no plan/todo
heuristics. Targets a session's default chat, or a specific peer chat via a
create_chat open link.

Also extends list_sessions with an optional session argument for a direct
single-session lookup by URI / open link (bypassing the other filters), so
session metadata stays with list_sessions while get_session_context focuses
purely on conversation data.

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

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-07-09 19:56:22 +02:00
..