Tachi67 commited on
Commit
d102094
·
1 Parent(s): 8479bee

Update ControllerFlow_ExtLib.py

Browse files
Files changed (1) hide show
  1. ControllerFlow_ExtLib.py +2 -2
ControllerFlow_ExtLib.py CHANGED
@@ -115,8 +115,8 @@ class ControllerFlow_ExtLib(ChatAtomicFlow):
115
  response = json.loads(api_output)
116
  return response
117
  except json.decoder.JSONDecodeError:
118
- new_goal = f"Here is your previous response {api_output}, it cannot be parsed with json.loads, please fix this issue."
119
  new_input_data = input_data.copy()
120
- new_input_data['goal'] = new_goal
121
  new_api_output = super().run(new_input_data)["api_output"].strip()
122
  return json.loads(new_api_output)
 
115
  response = json.loads(api_output)
116
  return response
117
  except json.decoder.JSONDecodeError:
118
+ new_goal = f"Here is your previous response {api_output}, it cannot be parsed with json.loads, please fix this issue. Provide your response only in JSON format."
119
  new_input_data = input_data.copy()
120
+ new_input_data['result'] = new_goal
121
  new_api_output = super().run(new_input_data)["api_output"].strip()
122
  return json.loads(new_api_output)