Interface StepConfig

Configuration for a single workflow step node.

Exactly one of tool, gmi, human, extension, or subgraph must be provided to specify the execution strategy. All remaining fields are optional policies.

interface StepConfig {
    tool?: string;
    gmi?: {
        instructions: string;
        executionMode?: "single_turn";
        maxTokens?: number;
    };
    human?: {
        prompt: string;
    };
    extension?: {
        extensionId: string;
        method: string;
    };
    subgraph?: CompiledExecutionGraph;
    memory?: MemoryPolicy;
    discovery?: DiscoveryPolicy;
    guardrails?: GuardrailPolicy;
    requiresApproval?: boolean;
    onFailure?: "abort" | "skip" | "retry";
    retryPolicy?: {
        maxAttempts: number;
        backoff: "exponential" | "linear" | "fixed";
        backoffMs: number;
    };
    timeout?: number;
    effectClass?: "external" | "human" | "pure" | "read" | "write";
    voice?: VoiceNodeConfig;
}

Properties

tool?: string

Name of a registered ITool to invoke.

gmi?: {
    instructions: string;
    executionMode?: "single_turn";
    maxTokens?: number;
}

General Model Invocation config. executionMode is always overridden to 'single_turn' inside a workflow to keep execution deterministic.

Type declaration

  • instructions: string
  • Optional executionMode?: "single_turn"

    Ignored at runtime — always coerced to 'single_turn' by the workflow compiler.

  • Optional maxTokens?: number

    Hard cap on LLM output tokens for this step.

human?: {
    prompt: string;
}

Human-in-the-loop step; suspends the run until a human provides a response.

Type declaration

  • prompt: string
extension?: {
    extensionId: string;
    method: string;
}

Call a method on a registered extension.

Type declaration

  • extensionId: string
  • method: string

Delegate to a previously compiled sub-workflow or agent graph.

memory?: MemoryPolicy

Memory read/write policy for this step.

discovery?: DiscoveryPolicy

Capability discovery policy applied before execution.

guardrails?: GuardrailPolicy

Declarative guardrail policy applied to input and/or output.

requiresApproval?: boolean

When true, execution suspends and waits for human approval before proceeding.

onFailure?: "abort" | "skip" | "retry"

What to do when the step fails.

retryPolicy?: {
    maxAttempts: number;
    backoff: "exponential" | "linear" | "fixed";
    backoffMs: number;
}

Automatic retry configuration. Only used when onFailure is 'retry'.

Type declaration

  • maxAttempts: number
  • backoff: "exponential" | "linear" | "fixed"
  • backoffMs: number
timeout?: number

Maximum wall-clock execution time in milliseconds.

effectClass?: "external" | "human" | "pure" | "read" | "write"

Side-effect classification used by the runtime for scheduling decisions.

Voice pipeline node configuration. When provided alongside executorConfig.type: 'voice', these settings are forwarded to the VoiceNodeExecutor. Typically set via the voiceNode() builder rather than directly through StepConfig.