TL;DR
Add an optional external: boolean flag to ToolPart in the message schema, so plugins can mark tool call results as externally produced (not from the built-in tool execution pipeline).
More detail
Currently, ToolPart has no way to indicate whether the tool result was produced by the core tool runner or injected externally (e.g. by a plugin providing its own tool results via the server API). This flag enables downstream consumers (TUI, plugins) to distinguish externally-produced results.
This is a prerequisite for the server /tool endpoint (which injects external tool results into sessions).
Part of the plugin primitives work tracked in #20018 (split from #21687).
TL;DR
Add an optional
external: booleanflag toToolPartin the message schema, so plugins can mark tool call results as externally produced (not from the built-in tool execution pipeline).More detail
Currently,
ToolParthas no way to indicate whether the tool result was produced by the core tool runner or injected externally (e.g. by a plugin providing its own tool results via the server API). This flag enables downstream consumers (TUI, plugins) to distinguish externally-produced results.This is a prerequisite for the server
/toolendpoint (which injects external tool results into sessions).Part of the plugin primitives work tracked in #20018 (split from #21687).