genkit icon indicating copy to clipboard operation
genkit copied to clipboard

Long-Running Tools

Open mbleigh opened this issue 7 months ago • 0 comments

Two classes of problem to tackle:

  1. Tools that take too long to wait on (need some form of "LRO" support)
  2. Tools that feel long because they have no intermediate status updates

For (1) I think we need some mechanism of synthetic conversation retriggering -- kinda complicated but basically the tool would respond with a "result pending, id: foo" and then later we'd inject a synthetic check_operation(foo) tool request with a tool result completing the original request.

For (2) we can choose between tools having streaming result support or tools having a separate statusSchema or progressSchema that can periodically emit things

Running into these classes of problems working on code-related agents in Genkit.

mbleigh avatar May 19 '25 23:05 mbleigh