mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-07-31 15:47:05 +00:00
chore: Roll back json parsing code (#637)
See [here](https://github.com/eosphoros-ai/DB-GPT/pull/626#discussion_r1336569182)
This commit is contained in:
commit
48aa8b8c85
@ -21,9 +21,9 @@ class ChatDashboardOutputParser(BaseOutputParser):
|
||||
super().__init__(sep=sep, is_stream_out=is_stream_out)
|
||||
|
||||
def parse_prompt_response(self, model_out_text):
|
||||
# clean_str = super().parse_prompt_response(model_out_text)
|
||||
print("clean prompt response:", model_out_text)
|
||||
response = json.loads(model_out_text)
|
||||
clean_str = super().parse_prompt_response(model_out_text)
|
||||
print("clean prompt response:", clean_str)
|
||||
response = json.loads(clean_str)
|
||||
chart_items: List[ChartItem] = []
|
||||
if not isinstance(response, list):
|
||||
response = [response]
|
||||
|
Loading…
Reference in New Issue
Block a user