Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyGraph ¶
ApplyGraph merges a Studio graph into a scenario, replacing the main workflow and any named subgraph workflows present in the graph payload.
func GenerateBuilderCode ¶
GenerateBuilderCode renders a builder-style Go snippet for the scenario workflow.
Types ¶
type GraphEdge ¶
type GraphEdge struct {
From string `json:"from"`
To string `json:"to"`
Condition string `json:"condition,omitempty"`
}
GraphEdge connects two workflow nodes.
type GraphNode ¶
type GraphNode struct {
ID string `json:"id"`
Kind string `json:"kind"`
Ref string `json:"ref,omitempty"`
Input json.RawMessage `json:"input,omitempty"`
Condition string `json:"condition,omitempty"`
DependsOn []string `json:"depends_on,omitempty"`
Interrupt bool `json:"interrupt,omitempty"`
Resumable bool `json:"resumable"`
ResumeHint string `json:"resume_hint,omitempty"`
}
GraphNode is a workflow node for visualization.
type GraphPosition ¶
GraphPosition stores a Studio canvas coordinate for a node.
type GraphView ¶
type GraphView struct {
ID string `json:"id,omitempty"`
Nodes []GraphNode `json:"nodes"`
Edges []GraphEdge `json:"edges"`
Layout map[string]GraphPosition `json:"layout,omitempty"`
}
GraphView describes one workflow DAG.
type ScenarioGraph ¶
type ScenarioGraph struct {
Name string `json:"name"`
Mode string `json:"mode"`
Workflow *GraphView `json:"workflow,omitempty"`
Workflows map[string]GraphView `json:"workflows,omitempty"`
}
ScenarioGraph is a Studio-friendly view of orchestration topology.
func ExportScenario ¶
func ExportScenario(scenario core.Scenario) ScenarioGraph
ExportScenario builds a nested graph from a core.Scenario.
func MergeLayout ¶
func MergeLayout(edited, exported ScenarioGraph) ScenarioGraph
MergeLayout copies canvas layout from edited onto exported, preserving node positions after save/reload.
Click to show internal directories.
Click to hide internal directories.