Skip to content

Improve subagent batch cancellation and partial-result recovery #1008

Description

@puri-adityakumar

Summary

fx can run multiple subagents in parallel, and recent work improves how their statuses are refreshed as they finish. However, a batch still needs clearer lifecycle behavior when children finish, fail, hang, or are cancelled.

Problem

If a batch contains several subagents:

  • One child may fail while others have already completed
  • The user may want to cancel the remaining children
  • A stuck child may keep the batch open indefinitely
  • Completed child results should not be lost because another child failed
  • It may be unclear whether the batch can be resumed safely

Proposal

Improve subagent batch lifecycle handling by:

  • Showing clear states such as running, completed, failed, cancelled, and timed out
  • Preserving completed child results when another child fails
  • Supporting cancellation of the remaining batch
  • Ensuring child shutdown has a bounded timeout
  • Showing a final batch summary
  • Making interrupted batch state recoverable where practical

Scope suggestion

This should be designed separately from ACP prompt queueing. The first step could be a design and test change for deterministic child states, cancellation, and partial results before adding a larger resume workflow.

I did not find an existing fx issue specifically covering this complete subagent batch lifecycle.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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