Skip to content

Declarative dependency-aware task-graph with parallel execution and automatic conflict resolution for plugin sub-agents #3613

@sophiaso

Description

@sophiaso

Describe the feature or problem you'd like to solve

Declarative dependency-aware task-graph with parallel execution and automatic conflict resolution for plugin sub-agents

Proposed solution

This is a follow-up to @github/copilot-cli/issues/3568 (which was closed and I don't have permission to reopen).

Add a built-in, declarative task-graph schema to Copilot CLI plugins, allowing plugin authors to define tasks, their dependencies/order, and conflict resolution strategies. Copilot CLI would then:

  • Parse the dependency graph
  • Run parallelizable tasks concurrently and sequential ones in order
  • Handle conflicts between parallel tasks (e.g., serialize, merge, or rerun as needed)
  • Return structured per-task results to support conditional workflows

This would reduce boilerplate, simplify orchestrator plugins, and improve reliability for complex, multi-step scenarios.

Example prompts or workflows

A scenario for .NET repo upgrades:

  1. Upgrade .NET (must finish first)
  2. Fix vulnerability A, B, C (run in parallel, but could conflict on shared files)
  3. Deploy (wait for all fixes to succeed)

Sample YAML task-graph schema:

tasks:
  - id: upgrade
    agent: dotnet-upgrade-agent
    prompt: "Upgrade the project from net6 to net8"
  - id: fix-a
    agent: security-agent
    prompt: "Fix vulnerability CVE-A"
    dependsOn: [upgrade]
  - id: fix-b
    agent: security-agent
    prompt: "Fix vulnerability CVE-B"
    dependsOn: [upgrade]
  - id: fix-c
    agent: security-agent
    prompt: "Fix vulnerability CVE-C"
    dependsOn: [upgrade]
  - id: deploy
    agent: deploy-agent
    prompt: "Deploy the updated app to Azure"
    dependsOn: [fix-a, fix-b, fix-c]
on_conflict: serialize   # e.g. serialize | merge | rerun-affected

Benefits:

  • Plugin authors describe dependencies instead of coding their own dispatch engine.
  • Copilot CLI resolves parallelism and conflicts for them.
  • Structured per-task results returned (pass/fail, output, logs, etc.).
  • Enables orchestrator-style plugins for batch refactor, multi-repo actions, etc.

Additional context

Current plugin task tool exposes parallel dispatch, but still requires imperative handling of ordering, conflict resolution and result management. Is a declarative, dependency-aware task-graph (with automatic parallelization + conflict resolution + structured results) something you'd consider?

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:agentsSub-agents, fleet, autopilot, plan mode, background agents, and custom agentsarea:pluginsPlugin system, marketplace, hooks, skills, extensions, and custom agents
    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions