Skip to content
Snippets Groups Projects
Unverified Commit 0f4eaee8 authored by Logan's avatar Logan Committed by GitHub
Browse files

fix tests (#11482)

parent 0c0ba477
No related branches found
No related tags found
No related merge requests found
...@@ -50,10 +50,14 @@ def default_output_response_parser(llm_output: str) -> str: ...@@ -50,10 +50,14 @@ def default_output_response_parser(llm_output: str) -> str:
llm_output_parsed = re.search( llm_output_parsed = re.search(
pattern=r"JSONPath:\s+(.*)", string=llm_output pattern=r"JSONPath:\s+(.*)", string=llm_output
).groups()[0] ).groups()[0]
except Exception as exc: except Exception:
raise ValueError( logger.warning(
f"JSON Path could not be parsed in the LLM response after the 'JSONPath' identifier. Try passing a custom JSON path prompt and processor." f"JSON Path could not be parsed in the LLM response after the 'JSONPath' identifier. "
) from exc "Try passing a custom JSON path prompt and processor. "
"Proceeding with output as-is."
)
return llm_output
return llm_output_parsed return llm_output_parsed
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment