Skip to content

Commit 1074ce5

Browse files
authored
chore(langchain_v1)!: Remove ToolNode from agents (#33250)
Remove ToolNode from agents namespace. It should only be present in tools
1 parent 3d2f13a commit 1074ce5

File tree

3 files changed

+2
-6
lines changed

3 files changed

+2
-6
lines changed
Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
"""langgraph.prebuilt exposes a higher-level API for creating and executing agents and tools."""
22

33
from langchain.agents.react_agent import AgentState, create_agent
4-
from langchain.tools import ToolNode
54

65
__all__ = [
76
"AgentState",
8-
"ToolNode",
97
"create_agent",
108
]

libs/langchain_v1/tests/unit_tests/agents/test_react_agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@
3232

3333
from langchain.agents import (
3434
AgentState,
35-
ToolNode,
3635
create_agent,
3736
)
3837
from langchain.agents.react_agent import _validate_chat_history
3938
from langchain.tools import (
39+
ToolNode,
4040
InjectedState,
4141
InjectedStore,
4242
)

libs/langchain_v1/tests/unit_tests/agents/test_tool_node.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,8 @@
3232
from pydantic.v1 import BaseModel as BaseModelV1
3333
from typing_extensions import TypedDict
3434

35-
from langchain.agents import (
36-
ToolNode,
37-
)
3835
from langchain.tools import (
36+
ToolNode,
3937
InjectedState,
4038
InjectedStore,
4139
)

0 commit comments

Comments
 (0)