mirror of
https://github.com/open-gitagent/langship.sh.git
synced 2026-08-03 07:21:04 +02:00
feat(web): initialize Next.js project with Tailwind CSS and TypeScript setup
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
package models
|
||||
|
||||
// Item is a single data item flowing between nodes.
|
||||
type Item = map[string]any
|
||||
|
||||
// NodeOutput holds the outputs of a single node, keyed by output index.
|
||||
type NodeOutput = map[int][]Item
|
||||
|
||||
// ExecutionResult is the final result of a workflow execution.
|
||||
type ExecutionResult struct {
|
||||
ExecutionID string `json:"execution_id"`
|
||||
Status string `json:"status"`
|
||||
Outputs map[string]map[int][]Item `json:"outputs"`
|
||||
NodeOutputs map[string]map[int][]Item `json:"node_outputs"`
|
||||
Errors []string `json:"errors"`
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
package models
|
||||
|
||||
// NodeDef represents a single node in an n8n-compatible workflow.
|
||||
type NodeDef struct {
|
||||
ID string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
Type string `json:"type"`
|
||||
TypeVersion float64 `json:"typeVersion"`
|
||||
Parameters map[string]any `json:"parameters"`
|
||||
Credentials map[string]any `json:"credentials,omitempty"`
|
||||
Settings map[string]any `json:"settings,omitempty"`
|
||||
Position [2]float64 `json:"position"`
|
||||
}
|
||||
|
||||
// ConnectionDef represents a directed edge between two nodes.
|
||||
type ConnectionDef struct {
|
||||
SourceNode string
|
||||
SourceOutputIndex int
|
||||
TargetNode string
|
||||
TargetInputIndex int
|
||||
}
|
||||
|
||||
// WorkflowDefinition is the parsed internal representation of a workflow.
|
||||
type WorkflowDefinition struct {
|
||||
Name string `json:"name"`
|
||||
Nodes []NodeDef `json:"nodes"`
|
||||
Connections []ConnectionDef
|
||||
Settings map[string]any `json:"settings"`
|
||||
}
|
||||
Reference in New Issue
Block a user