Fix recipe steps display and DAG visualization

- Check multiple locations for nodes: dag.nodes, recipe.nodes, pipeline, steps
- Add dagre layout libraries for cytoscape DAG visualization
- Fix inputs parsing when stored as JSON string in Redis

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
gilesb
2026-01-11 20:21:24 +00:00
parent 209d416442
commit a6dd470623
4 changed files with 19 additions and 1 deletions

View File

@@ -155,10 +155,18 @@ async def get_recipe(
"output": "#f59e0b",
}
# Get nodes from dag - can be list or dict
# Get nodes from dag - can be list or dict, can be under "dag" or directly on recipe
dag = recipe.get("dag", {})
nodes = dag.get("nodes", [])
# Also check for nodes directly on recipe (alternative formats)
if not nodes:
nodes = recipe.get("nodes", [])
if not nodes:
nodes = recipe.get("pipeline", [])
if not nodes:
nodes = recipe.get("steps", [])
# Convert list of nodes to steps format
if isinstance(nodes, list):
for node in nodes: