Tachi67 commited on
Commit
68c934b
·
1 Parent(s): c2e2060

Update ControllerFlow_ExtLib.py

Browse files
Files changed (1) hide show
  1. ControllerFlow_ExtLib.py +2 -1
ControllerFlow_ExtLib.py CHANGED
@@ -108,7 +108,8 @@ class ControllerFlow_ExtLib(ChatAtomicFlow):
108
  response = json.loads(api_output)
109
  return response
110
  except json.decoder.JSONDecodeError:
 
111
  new_input_data = input_data.copy()
112
- new_input_data['result'] = "The previous respond cannot be parsed with json.loads. Make sure your next response is in JSON format."
113
  new_api_output = super().run(new_input_data)["api_output"].strip()
114
  return json.loads(new_api_output)
 
108
  response = json.loads(api_output)
109
  return response
110
  except json.decoder.JSONDecodeError:
111
+ new_goal = f"Here is your previous response {api_output}, it cannot be parsed with json.loads, please fix this issue."
112
  new_input_data = input_data.copy()
113
+ new_input_data['goal'] = new_goal
114
  new_api_output = super().run(new_input_data)["api_output"].strip()
115
  return json.loads(new_api_output)