mirror of
https://github.com/VinciGit00/Scrapegraph-ai.git
synced 2026-07-01 21:00:48 +08:00
fix: issue about parser
This commit is contained in:
parent
f9b121f765
commit
7eda6bc06b
@ -96,14 +96,12 @@ class GenerateAnswerNode(BaseNode):
|
||||
output_parser = get_structured_output_parser(self.node_config["schema"])
|
||||
format_instructions = "NA"
|
||||
else:
|
||||
if not isinstance(self.llm_model, ChatBedrock):
|
||||
output_parser = get_pydantic_output_parser(self.node_config["schema"])
|
||||
format_instructions = output_parser.get_format_instructions()
|
||||
output_parser = get_pydantic_output_parser(self.node_config["schema"])
|
||||
format_instructions = output_parser.get_format_instructions()
|
||||
|
||||
else:
|
||||
if not isinstance(self.llm_model, ChatBedrock):
|
||||
output_parser = JsonOutputParser()
|
||||
format_instructions = output_parser.get_format_instructions()
|
||||
output_parser = JsonOutputParser()
|
||||
format_instructions = output_parser.get_format_instructions()
|
||||
|
||||
if isinstance(self.llm_model, (ChatOpenAI, AzureChatOpenAI)) \
|
||||
and not self.script_creator \
|
||||
|
||||
@ -60,7 +60,9 @@ def search_on_web(query: str, search_engine: str = "Google",
|
||||
|
||||
elif search_engine.lower() == "searxng":
|
||||
url = f"http://localhost:{port}"
|
||||
params = {"q": query, "format": "json"}
|
||||
params = {"q": query,
|
||||
"format": "json",
|
||||
"engines": "google,duckduckgo,brave,qwant,bing"}
|
||||
|
||||
response = requests.get(url, params=params)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user