workflow

package
v1.0.6 Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compile

func Compile(def *definition.WorkflowDefinition, asyncTool func(toolName string) bool) (*runtime.Plan, error)

Compile 把 WorkflowDefinition 翻译为 runtime.Plan(依赖反转的关键一步)。

definition.Edge                    → PlanNode.DependsOn(纯拓扑,丢掉 condition)
definition.NodeStart/NodeEnd       → 编译期吸收(不进 plan,也不作为依赖)
definition.NodeAwait / async tool  → PlanNode.Async = true
NodeDefinition.InputMapping(expr)  → PlanNode.Resolve(expr 求值闭包)

asyncTool 由调用方注入(通常是 tool.Registry 的 "该工具是否 async" 判定)。

Types

This section is empty.

Jump to

Keyboard shortcuts

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