langgraph-supervisor
Installation
SKILL.md
LangGraph Supervisor Pattern
Coordinate multiple specialized agents with a central supervisor.
Basic Supervisor
from langgraph.graph import StateGraph, END
def supervisor(state: WorkflowState) -> WorkflowState:
"""Route to next worker based on state."""
if state["needs_analysis"]:
state["next"] = "analyzer"
elif state["needs_validation"]:
state["next"] = "validator"
else:
state["next"] = END
return state