← Lesson
Supervisor Plus a Sequential Subgraph
Joeven
Run
Reset
Python loads on first run
GRAPHS = { "billing": ["extract", "policy", "hitl", "apply"], "tech": ["logs", "brief", "patch", "tests"], } def pick(ticket): t = ticket.lower() if "refund" in t or "invoice" in t: return "billing" return "tech" def run(ticket): kind = pick(ticket) path = GRAPHS[kind] return {"kind": kind, "path": path, "hitl": "hitl" in path} print(run("Where is my invoice refund?")) print(run("job 17 timeout")) print("billing always HITL", run("refund")["hitl"]) print("tech has no apply money", "apply" not in run("timeout")["path"])
Run to execute this in your browser. Nothing is sent to a server.