mirror of
https://github.com/hwchase17/langchain
synced 2024-11-06 03:20:49 +00:00
Harrison/errors (#1276)
Co-authored-by: Kevin Huo <5000881+kwhuo68@users.noreply.github.com>
This commit is contained in:
parent
8a0751dadd
commit
bb53d9722d
@ -86,7 +86,6 @@ class GoogleSearchAPIWrapper(BaseModel):
|
|||||||
service = build("customsearch", "v1", developerKey=google_api_key)
|
service = build("customsearch", "v1", developerKey=google_api_key)
|
||||||
values["search_engine"] = service
|
values["search_engine"] = service
|
||||||
|
|
||||||
# TODO: Add error handling if keys are missing
|
|
||||||
return values
|
return values
|
||||||
|
|
||||||
def run(self, query: str) -> str:
|
def run(self, query: str) -> str:
|
||||||
|
@ -43,10 +43,8 @@ class WolframAlphaAPIWrapper(BaseModel):
|
|||||||
"Please install it with `pip install wolframalpha`"
|
"Please install it with `pip install wolframalpha`"
|
||||||
)
|
)
|
||||||
client = wolframalpha.Client(wolfram_alpha_appid)
|
client = wolframalpha.Client(wolfram_alpha_appid)
|
||||||
|
|
||||||
values["wolfram_client"] = client
|
values["wolfram_client"] = client
|
||||||
|
|
||||||
# TODO: Add error handling if keys are missing
|
|
||||||
return values
|
return values
|
||||||
|
|
||||||
def run(self, query: str) -> str:
|
def run(self, query: str) -> str:
|
||||||
|
Loading…
Reference in New Issue
Block a user