Class CompiledWorkflow

An execution-ready workflow produced by WorkflowBuilder.compile().

Wraps a CompiledExecutionGraph and a GraphRuntime, exposing the same three execution modes as the raw runtime:

  • invoke(input) — run to completion and return final artifacts.
  • stream(input) — run while yielding GraphEvent values at each step.
  • resume(checkpointId) — restore an interrupted run from a checkpoint.

Constructors

Methods

Constructors

Methods

  • Execute the workflow to completion and return the final artifacts payload.

    Parameters

    • input: unknown

      Must conform to the schema declared via .input().

    Returns Promise<unknown>

    The GraphState.artifacts value after all nodes complete.

  • Resume a previously interrupted workflow run from its latest checkpoint.

    Parameters

    • checkpointId: string

      Either the original run id or an exact checkpoint id.

    Returns Promise<unknown>

    The final GraphState.artifacts value after resumption completes.