Spaces:
Sleeping
Sleeping
apple muncy
commited on
Commit
·
3b081a7
1
Parent(s):
6b22cf4
bact to orig
Browse filesSigned-off-by: apple muncy <[email protected]>
app.py
CHANGED
@@ -52,7 +52,6 @@ tools = [
|
|
52 |
|
53 |
# Bind tools to the chat model
|
54 |
chat_with_tools = chat.bind_tools(tools)
|
55 |
-
tool_node=ToolNode(tools)
|
56 |
# Generate the AgentState and Agent graph
|
57 |
class AgentState(TypedDict):
|
58 |
messages: Annotated[list[AnyMessage], add_messages]
|
@@ -75,7 +74,7 @@ builder = StateGraph(AgentState)
|
|
75 |
|
76 |
# Define nodes: these do the work
|
77 |
builder.add_node("assistant", assistant)
|
78 |
-
builder.add_node("tools",
|
79 |
|
80 |
# Define edges: these determine how the control flow moves
|
81 |
builder.add_edge(START, "assistant")
|
|
|
52 |
|
53 |
# Bind tools to the chat model
|
54 |
chat_with_tools = chat.bind_tools(tools)
|
|
|
55 |
# Generate the AgentState and Agent graph
|
56 |
class AgentState(TypedDict):
|
57 |
messages: Annotated[list[AnyMessage], add_messages]
|
|
|
74 |
|
75 |
# Define nodes: these do the work
|
76 |
builder.add_node("assistant", assistant)
|
77 |
+
builder.add_node("tools",ToolNode(tools))
|
78 |
|
79 |
# Define edges: these determine how the control flow moves
|
80 |
builder.add_edge(START, "assistant")
|