orchestration

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 25, 2026 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AgentRegistry

type AgentRegistry interface {
	Agent(name string) (core.AgentRunner, bool)
}

type ConversationMemoryRewinder added in v0.3.0

type ConversationMemoryRewinder interface {
	RewindConversationMemory(ctx context.Context, runID, agentName string, keep int) error
}

ConversationMemoryRewinder truncates a run-scoped conversation memory to the first keep messages. Workflow time-travel uses it to rewind agent memory in step with rewound step outputs.

type RunnerOption

type RunnerOption func(*WorkflowRunner)

func WithAgentRegistry

func WithAgentRegistry(agents AgentRegistry) RunnerOption

func WithAuditSink added in v0.3.0

func WithAuditSink(sink audit.Sink) RunnerOption

WithAuditSink wires the audit sink used when a security policy denies a workflow tool invocation.

func WithBlobStore

func WithBlobStore(blobs runstate.BlobStore) RunnerOption

func WithHumanGate

func WithHumanGate(gate core.HumanGate) RunnerOption

func WithMemoryRewinder added in v0.3.0

func WithMemoryRewinder(memory ConversationMemoryRewinder) RunnerOption

WithMemoryRewinder wires the capability used to rewind run-scoped conversation memory when a workflow is rewound via time-travel.

func WithOutputRedactor added in v0.1.3

func WithOutputRedactor(redactor governance.OutputRedactor) RunnerOption

WithOutputRedactor wires an output redactor for persisted workflow step outputs.

func WithSecurityPolicy added in v0.3.0

func WithSecurityPolicy(policy security.Policy) RunnerOption

WithSecurityPolicy wires the same authorization policy used by the autonomous tool loop, so NodeTool executions cannot bypass RBAC.

func WithToolApprovalEvaluator added in v0.3.0

func WithToolApprovalEvaluator(evaluator core.ToolApprovalEvaluator) RunnerOption

func WithWorkflowToolPolicy added in v0.1.1

func WithWorkflowToolPolicy(policy governance.ToolPolicy) RunnerOption

WithWorkflowToolPolicy wires a per-invocation governance policy applied to NodeTool executions inside a workflow. The policy is evaluated before each tool call and can deny the invocation.

type ToolRegistry

type ToolRegistry interface {
	ResolveTool(ctx context.Context, tool core.Tool) (core.ToolExecutor, bool, error)
}

type WorkflowPausedError

type WorkflowPausedError struct {
	RunID  string
	NodeID string
	Token  string
}

func (WorkflowPausedError) Error

func (e WorkflowPausedError) Error() string

type WorkflowRunner

type WorkflowRunner struct {
	// contains filtered or unexported fields
}

func NewWorkflowRunner

func NewWorkflowRunner(tools ToolRegistry, runs runstate.Repository, events core.EventSink, opts ...RunnerOption) *WorkflowRunner

func (*WorkflowRunner) RestoreSnapshotAndRun added in v0.2.0

func (r *WorkflowRunner) RestoreSnapshotAndRun(ctx context.Context, scenario core.Scenario, runID string, restored runstate.RunSnapshot) error

RestoreSnapshotAndRun replaces the current run snapshot with a historical revision and reruns the workflow from that restored state forward.

func (*WorkflowRunner) Resume

func (r *WorkflowRunner) Resume(ctx context.Context, scenario core.Scenario, runID string) error

func (*WorkflowRunner) ResumeFromStep added in v0.2.0

func (r *WorkflowRunner) ResumeFromStep(ctx context.Context, scenario core.Scenario, runID, nodeID string) error

ResumeFromStep truncates outputs for the node and its downstream steps, then reruns the workflow from that node forward.

func (*WorkflowRunner) Run

func (r *WorkflowRunner) Run(ctx context.Context, scenario core.Scenario, runID string) error

func (*WorkflowRunner) SaveStepOutput added in v0.3.0

func (r *WorkflowRunner) SaveStepOutput(ctx context.Context, scenario core.Scenario, runID, nodeID string, value any) error

SaveStepOutput persists a workflow node output and advances CurrentNodeID.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL