14 lines
420 B
Python
14 lines
420 B
Python
from langgraph.graph import StateGraph
|
|
from src.nodes import generate_response
|
|
from typing import Dict, Any
|
|
|
|
def build_graph() -> StateGraph:
|
|
"""
|
|
Builds a simple StateGraph with a single node that echoes user input.
|
|
"""
|
|
graph = StateGraph()
|
|
# Add the echo node
|
|
graph.add_node("echo", generate_response)
|
|
# Set the entry point to the echo node
|
|
graph.set_entry_point("echo")
|
|
return graph |