Skip to content

feat(agent-manager): route peer replies to source sessions - #13877

Merged
marius-kilocode merged 5 commits into
mainfrom
fix-agent-manager-session-routing
Sep 7, 2026
Merged

marius-kilocode merged 5 commits into
mainfrom
fix-agent-manager-session-routing

Conversation

@marius-kilocode

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Agent Manager prompts could reach another session, but the receiving agent had no reliable reference to the originating session and could not return its result.

Why This Change Was Made

The existing prompt action now carries an optional request-scoped reply reference. The bridge injects peer context, validates the original sender and workspace, routes replies through the existing session queue, and reconstructs routes from persisted peer-request metadata after an extension restart.

User Impact

Agents can send a prompt to another Agent Manager session and reply to the exact originating session. Busy sessions queue replies through the normal prompt path, local/sidebar source sessions are supported, and peer payloads are bounded and marked as untrusted data.

Evidence

  • Agent Manager regression suite: 441 tests passed.
  • CLI Agent Manager tool tests: 45 tests passed.
  • Extension compile, lint, and typecheck passed.
  • CLI typecheck and OpenCode annotation checks passed.
  • Isolated live Agent Manager test verified a request from Agent A reached Agent B and a replyTo response reached Agent A.

The implementation does not add cross-server routing. Reply recovery depends on the persisted peer-request message remaining available in the target session.

…sion-routing

# Conflicts:
#	packages/kilo-vscode/src/agent-manager/orchestration-bridge.ts
#	packages/kilo-vscode/tests/unit/agent-manager-orchestration-bridge.test.ts
@kilo-code-bot

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants