MCPcopy Create free account
hub / github.com/betta-tech/byo-coding-agent / DelegateTool

Struct DelegateTool

delegate.go:22–24  ·  view source on GitHub ↗

DelegateTool exposes one Subagent to the model as a callable tool. The model sees "delegate_ " with the subagent's description and a single `task` parameter. When called, the subagent runs in its own agent loop and returns its final answer as the tool result. Lives in package main rat

Source from the content-addressed store, hash-verified

20// cycle (tool → subagent → agent → tool). The Tool interface itself is
21// defined in internal/tool/, so we still implement it cleanly.
22type DelegateTool struct {
23 Subagent subagent.Subagent
24}
25
26func (d *DelegateTool) Definition() api.ToolDef {
27 return api.ToolDef{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected