Skip to content

Graph — nested subgraphs & bounded parallel execution #61

Description

@zenithruneblade

Add nested subgraphs and bounded parallel branches after the local multimodal and runtime-policy paths are proven. The current Graph adapter is serial; this is an advanced follow-up.

Checklist

  • Admit one versioned topology under ADR 24: isolated typed branch state, parent/child identities, bounded fan-out and explicit join/reduction. A waiting branch allows independent siblings to continue.
  • Reuse the capability handshake per branch: Dispatcher selects; Orchestrator starts the Animator and/or activates its model; resume dispatches afresh. Cover a running llama.cpp router with an unloaded or already-loading target, without duplicate loads or inference-triggered autoload.
  • Resolve only branches and router alternatives declared by the pinned Scroll. Admission may fold those alternatives into one typed execution projection using exact predicates and capability evidence; it must not generate edges or rewrite the live Graph. A missing/cold capability yields the declared wait, refusal or bounded same-road fallback, never an undeclared semantic branch.
  • Integrate Orchestration — multi-model switching & resource policy #16's resource policy and Dispatch — configurable ranking & bounded fallback #17's configurable ranking/fallback. Waiting branches hold no grants; competing branches preserve drain/ownership rules and have bounded wait/retry budgets instead of unbounded model switching.
  • Define parent/child deadline, cancellation and failure propagation; settle every started branch. Checkpoint branch/join progress and recover only admitted boundaries using Workers & Ghouls — durable service jobs and recovery #22's service-attempt contract; never serialize live handles or blindly replay uncertain effects.
  • Demonstrate one nested two-branch workflow and two competing Runs, including one cold capability, one independent warm branch, a join and cancellation. Retain deterministic/recovery fixtures plus a named-host receipt correlated through Observability / Oculus — correlate one Run across execution #36.

Completion dependencies: #16, #17 and #22. These already lead back to #8 and the earlier runtime/multimodal foundations. Contract proposals and fixtures may start earlier; this work does not block those foundations.

Open decision: Agree the first subgraph/branch checkpoint schema and join/cancellation semantics before implementation. Preserve #21's extension registration and #1's typed configuration boundaries.

Advanced review: #62 composes this topology with concurrent independent Runs, road decisions, worker progress and Altar evidence. It adds no completion blocker to this bounded two-branch slice.

Later: Distributed graphs, adaptive graph rewriting and durable cross-host reservations.

References: Graph — ADR 24 · Orchestrator — ADR 23 · Dispatcher — ADR 22 · Workers — ADR 14.

Scroll/Graph contract split: #29 owns portable Spell/Scroll registration, publication, immutable resolution and Run pinning. This issue owns the advanced Graph/subgraph execution adapter for an already admitted score. #63/#64 map the extension and local configuration surfaces; none may rewrite a live Graph.

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

    area:runtimeAgents, Graph, dispatch, orchestration, capabilities and workers.needs-designAn issue-specific implementation choice remains open; see Open decision.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions