mirror of
https://github.com/hwchase17/langchain.git
synced 2025-09-12 12:59:07 +00:00
community[patch]: deprecating remaining google_community integrations (#20471)
Deprecating remaining google community integrations
This commit is contained in:
@@ -2,12 +2,18 @@
|
||||
|
||||
from typing import Optional
|
||||
|
||||
from langchain_core._api.deprecation import deprecated
|
||||
from langchain_core.callbacks import CallbackManagerForToolRun
|
||||
from langchain_core.tools import BaseTool
|
||||
|
||||
from langchain_community.utilities.google_search import GoogleSearchAPIWrapper
|
||||
|
||||
|
||||
@deprecated(
|
||||
since="0.0.33",
|
||||
removal="0.2.0",
|
||||
alternative_import="langchain_google_community.GoogleSearchRun",
|
||||
)
|
||||
class GoogleSearchRun(BaseTool):
|
||||
"""Tool that queries the Google search API."""
|
||||
|
||||
@@ -28,6 +34,11 @@ class GoogleSearchRun(BaseTool):
|
||||
return self.api_wrapper.run(query)
|
||||
|
||||
|
||||
@deprecated(
|
||||
since="0.0.33",
|
||||
removal="0.2.0",
|
||||
alternative_import="langchain_google_community.GoogleSearchResults",
|
||||
)
|
||||
class GoogleSearchResults(BaseTool):
|
||||
"""Tool that queries the Google Search API and gets back json."""
|
||||
|
||||
|
Reference in New Issue
Block a user