Add trusted handlers for addressable agent submissions #277
FredKSchott
started this conversation in
Feature Request
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Problem
Addressable agents currently process every
dispatch()input through the coordinator model. Application code can configure the agent and expose model-callable tools, but it cannot handle a typed dispatched command with access to the initialized Flue session.This limits applications that need deterministic orchestration around named subagents. For example, an application may need trusted code to:
session.task(..., { agent, result, tools, images, signal });Image bytes in particular should not need to pass through coordinator text, tool output, or persisted JSON commands.
Today,
dispatch()accepts JSON-like input,createAgent()initialization receives no session or harness, and custom tools intentionally receive no session handle. Direct HTTP images attach to the coordinator turn and do not automatically propagate to isolated named subagents.Possible API
Add an optional application-owned handler for addressable dispatched submissions, for example:
Naming is flexible (
onDispatch,handleSubmission, typed command handlers, etc.). Useful properties would be:FlueSession, or a narrower task runner, along with parsed input, an abort signal, and submission/dispatch correlation.session.task()options, including structured result schemas, dynamic tools, and images.dispatch()commands.A narrower alternative would expose a trusted
task()runner rather than the full session.Implementation observation
The internal boundary appears close to what is needed: submission processing initializes the agent session before applying the submission input. A possible implementation would select the configured dispatch handler at that boundary while preserving the existing input-application, timeout, abort, journal, recovery, and settlement behavior.
Why not an application workaround?
{ message, images }attaches images to the coordinator rather than the isolated named subagent.ctx.init()duplicates orchestration infrastructure for applications centered on persistent agents.This could also support deterministic command handling beyond images: schema-selected specialist calls, bounded repair loops, routing pipelines, and similar orchestration without requiring a coordinator model turn.
Beta Was this translation helpful? Give feedback.
All reactions