Skip to content

Add slash commands to switch between agents with context transfer for small local models #2055

@k33g

Description

@k33g

Problem

The task handoff system between agents works poorly with small local models (e.g., when used with Docker Model Runner) because their parameter count and context window size are insufficient.

Proposed Solution

In this context (small local models), it would be useful to have slash commands that allow switching from one agent to another while transferring the current context (conversation, last message, etc.). This would greatly improve the user experience when using Docker Agent with small local models.

Example

Given the following configuration:

docker agent config:

root:
  sub_agents: [coder, reviewer]

The following slash commands could be available:

Command Description
/switch <agent> Switch to the specified agent without context
/switch-with-context <agent> Switch to the specified agent and transfer the full conversation context
/switch-with-last-message <agent> Switch to the specified agent and transfer only the last message

Available commands with the example config above:

  • /switch coder
  • /switch reviewer
  • /switch root
  • /switch-with-context coder
  • /switch-with-context reviewer
  • /switch-with-context root
  • /switch-with-last-message coder
  • /switch-with-last-message reviewer
  • /switch-with-last-message root

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions