[GH-ISSUE #2066] [langchain]: importing of Tool has been removed in langchain.tools #264

Closed
opened 2026-02-17 17:19:31 -05:00 by yindo · 0 comments
Owner

Originally created by @Golden-Pigeon on GitHub (Jan 4, 2026).
Original GitHub issue: https://github.com/langchain-ai/docs/issues/2066

Type of issue

issue / bug

Language

Python

Description

In this page, there is following code

from langchain.tools import Tool
from langchain_google_community import GoogleSearchAPIWrapper

search = GoogleSearchAPIWrapper()

tool = Tool(
    name="google_search",
    description="Search Google for recent results.",
    func=search.run,
)

However, importing of Tool has been removed in langchain.tools in https://github.com/langchain-ai/langchain/pull/32228.

Now, we can import Tool using from langchain_core.tools.simple import Tool, but I'm not sure whether it is the correct usage.

Originally created by @Golden-Pigeon on GitHub (Jan 4, 2026). Original GitHub issue: https://github.com/langchain-ai/docs/issues/2066 ### Type of issue issue / bug ### Language Python ### Description In [this page](https://docs.langchain.com/oss/python/integrations/tools/google_search), there is following code ```python from langchain.tools import Tool from langchain_google_community import GoogleSearchAPIWrapper search = GoogleSearchAPIWrapper() tool = Tool( name="google_search", description="Search Google for recent results.", func=search.run, ) ``` However, importing of Tool has been removed in langchain.tools in https://github.com/langchain-ai/langchain/pull/32228. Now, we can import `Tool` using `from langchain_core.tools.simple import Tool`, but I'm not sure whether it is the correct usage.
yindo added the langchainexternal labels 2026-02-17 17:19:31 -05:00
yindo closed this issue 2026-02-17 17:19:31 -05:00
yindo changed title from [langchain]: importing of Tool has been removed in langchain.tools to [GH-ISSUE #2066] [langchain]: importing of Tool has been removed in langchain.tools 2026-06-05 17:25:57 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/docs#264